wlzboy
2026-01-12 45d90d1e7ba86286e998d1ac4d2cba8e98cd059b
1
2
3
4
5
6
7
8
-- 在sys_dept表中添加department_id字段,用于记录SQL Server中的departmentID
-- 该字段用于部门同步功能
 
-- 添加department_id字段
ALTER TABLE sys_dept ADD COLUMN department_id INT NULL COMMENT 'SQL Server中的部门ID';
 
-- 为department_id字段创建索引,提高查询效率
CREATE INDEX idx_department_id ON sys_dept(department_id);