Properties

Owner: HumanResources 
Creation Date: 04/26/2006 
Located On: PRIMARY 
Data Size KB:
Index Size KB: 40 
Rows:
Description: Work shift lookup table. 

Columns

Name Data Type Length NULL Default IsIdentity IsGUID Description
    ShiftID  tinyint          Primary key for Shift records. 
    Name  Name  100          Shift description. 
    StartTime  datetime          Shift start time. 
    EndTime  datetime          Shift end time. 
    ModifiedDate  datetime    (getdate())      Date and time the record was last updated. 
Total: 5 column(s)

Identity column

Name Seed Increment Not for replication
  ShiftID   

Indexes

Index Primary Unique Description
  PK_Shift_ShiftID      Primary key (clustered) constraint 
  AK_Shift_Name      Unique nonclustered index. 
  AK_Shift_StartTime_EndTime      Unique nonclustered index. 
Total: 3 index(es)

Referencing Tables

Table Foreign Key Primary Key or Unique Constraint
  HumanResources.EmployeeDepartmentHistory  FK_EmployeeDepartmentHistory_Shift_ShiftID  PK_Shift_ShiftID 
Total: 1 table(s)

Objects that [HumanResources].[Shift] depends on

Object Name Owner Object Type Dep Level
  Name  dbo  User Defined type 
Total: 1 object(s)

Objects that depend on [HumanResources].[Shift]

Object Name Owner Object Type Dep Level
  EmployeeDepartmentHistory  HumanResources  Table 
  vEmployeeDepartment  HumanResources  View 
  vEmployeeDepartmentHistory  HumanResources  View 
Total: 3 object(s)

SQL

CREATE TABLE [Shift] (
    [ShiftID] [tinyint] IDENTITY (1, 1) NOT NULL ,
    [Name] [Name] NOT NULL ,
    [StartTime] [datetime] NOT NULL ,
    [EndTime] [datetime] NOT NULL ,
    [ModifiedDate] [datetime] NOT NULL CONSTRAINT [DF_Shift_ModifiedDate] DEFAULT (getdate()),
    CONSTRAINT [PK_Shift_ShiftID] PRIMARY KEY  CLUSTERED
    (
        [ShiftID]
    )  ON [PRIMARY]
) ON [PRIMARY]
GO


See Also

List of tables