From dbscript Online Help
wikibot
Table
|
HumanResources.EmployeeDepartmentHistory
|
Column
|
Data Type
|
Nullable
|
Default
|
PK
|
Index
|
EmployeeID
|
int
|
not null
|
|
PK_EmployeeDepartmentHistory_EmployeeID_StartDate_DepartmentID
|
|
DepartmentID
|
smallint
|
not null
|
|
PK_EmployeeDepartmentHistory_EmployeeID_StartDate_DepartmentID
|
IX_EmployeeDepartmentHistory_DepartmentID
|
ShiftID
|
tinyint
|
not null
|
|
PK_EmployeeDepartmentHistory_EmployeeID_StartDate_DepartmentID
|
IX_EmployeeDepartmentHistory_ShiftID
|
StartDate
|
datetime
|
not null
|
|
PK_EmployeeDepartmentHistory_EmployeeID_StartDate_DepartmentID
|
|
EndDate
|
datetime
|
null
|
|
|
|
ModifiedDate
|
datetime
|
not null
|
(getdate())
|
|
|
automatically generated
Table
|
HumanResources.EmployeeDepartmentHistory
|
Description
|
Employee department transfers.
|
Column
|
Data Type
|
Nullable
|
Default
|
Description
|
PK / Index
|
EmployeeID
|
int
|
not null
|
|
Employee identification number. Foreign key to Employee.EmployeeID.
|
PK_EmployeeDepartmentHistory_EmployeeID_StartDate_DepartmentID
|
DepartmentID
|
smallint
|
not null
|
|
Department in which the employee worked including currently. Foreign key to Department.DepartmentID.
|
PK_EmployeeDepartmentHistory_EmployeeID_StartDate_DepartmentIDIX_EmployeeDepartmentHistory_DepartmentID
|
ShiftID
|
tinyint
|
not null
|
|
Identifies which 8-hour shift the employee works. Foreign key to Shift.Shift.ID.
|
PK_EmployeeDepartmentHistory_EmployeeID_StartDate_DepartmentIDIX_EmployeeDepartmentHistory_ShiftID
|
StartDate
|
datetime
|
not null
|
|
Date the employee started work in the department.
|
PK_EmployeeDepartmentHistory_EmployeeID_StartDate_DepartmentID
|
EndDate
|
datetime
|
null
|
|
Date the employee left the department. NULL = Current department.
|
|
ModifiedDate
|
datetime
|
not null
|
(GETDATE())
|
Date and time the record was last updated.
|
|