Tables [dbo].[SafetySystemPersonnel]
Properties
PropertyValue
CollationSQL_Latin1_General_CP1_CI_AS
HeapYes
Row Count (~)11
Created5:32:35 PM Wednesday, January 2, 2008
Last Modified9:19:39 AM Friday, November 8, 2024
Columns
NameData TypeMax Length (Bytes)Allow NullsIdentityDefault
Primary Key PK_SafetySystemPersonnel: SafetySystemPersonnelIDSafetySystemPersonnelIDint4
No
1 - 1
Foreign Keys FK_SafetySystemPersonnel_Sysuser: [dbo].[Sysuser].SysuserFIDIndexes IX_SafetySystemPersonnel_SysuserFID: SysuserFIDSysuserFIDint4
No
LastPhysicalDatedatetime8
Yes
NextPhysicalDatedatetime8
Yes
LicenseExpiresDatedatetime8
Yes
AdministrativeHoldFlagbit1
No
((0))
LastMVRDatedatetime8
Yes
NextMVRDatedatetime8
Yes
LastBackgroundCheckDatedatetime8
Yes
NextBackgroundCheckDatedatetime8
Yes
BackgroundCheckCIDvarchar(64)64
Yes
LicenseNumbervarchar(32)32
Yes
LicenseClassvarchar(32)32
Yes
Check Constraints CK_SafetySystemPersonnel_Seniority : ([Seniority] IS NULL OR [Seniority]>(0))Seniorityint4
Yes
Indexes Indexes
NameColumnsUniqueFill Factor
Primary Key PK_SafetySystemPersonnel: SafetySystemPersonnelIDPK_SafetySystemPersonnelSafetySystemPersonnelID
Yes
80
IX_SafetySystemPersonnel_SysuserFIDSysuserFID
Yes
Check Constraints Check Constraints
NameOn ColumnConstraint
CK_SafetySystemPersonnel_SenioritySeniority([Seniority] IS NULL OR [Seniority]>(0))
Foreign Keys Foreign Keys
NameDeleteColumns
FK_SafetySystemPersonnel_SysuserCascadeSysuserFID->[dbo].[Sysuser].[SysUserID]
Permissions
TypeActionOwning Principal
GrantDeleteMssExec
GrantInsertMssExec
GrantSelectMssExec
GrantUpdateMssExec
SQL Script
CREATE TABLE [dbo].[SafetySystemPersonnel]
(
[SafetySystemPersonnelID] [int] NOT NULL IDENTITY(1, 1),
[SysuserFID] [int] NOT NULL,
[LastPhysicalDate] [datetime] NULL,
[NextPhysicalDate] [datetime] NULL,
[LicenseExpiresDate] [datetime] NULL,
[AdministrativeHoldFlag] [bit] NOT NULL CONSTRAINT [DF_SafetySystemPersonnel_AdministrativeHoldFlag] DEFAULT ((0)),
[LastMVRDate] [datetime] NULL,
[NextMVRDate] [datetime] NULL,
[LastBackgroundCheckDate] [datetime] NULL,
[NextBackgroundCheckDate] [datetime] NULL,
[BackgroundCheckCID] [varchar] (64) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[LicenseNumber] [varchar] (32) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[LicenseClass] [varchar] (32) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[Seniority] [int] NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[SafetySystemPersonnel] ADD CONSTRAINT [CK_SafetySystemPersonnel_Seniority] CHECK (([Seniority] IS NULL OR [Seniority]>(0)))
GO
ALTER TABLE [dbo].[SafetySystemPersonnel] ADD CONSTRAINT [PK_SafetySystemPersonnel] PRIMARY KEY NONCLUSTERED  ([SafetySystemPersonnelID]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
CREATE UNIQUE NONCLUSTERED INDEX [IX_SafetySystemPersonnel_SysuserFID] ON [dbo].[SafetySystemPersonnel] ([SysuserFID]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[SafetySystemPersonnel] ADD CONSTRAINT [FK_SafetySystemPersonnel_Sysuser] FOREIGN KEY ([SysuserFID]) REFERENCES [dbo].[Sysuser] ([SysUserID]) ON DELETE CASCADE
GO
GRANT SELECT ON  [dbo].[SafetySystemPersonnel] TO [MssExec]
GRANT INSERT ON  [dbo].[SafetySystemPersonnel] TO [MssExec]
GRANT DELETE ON  [dbo].[SafetySystemPersonnel] TO [MssExec]
GRANT UPDATE ON  [dbo].[SafetySystemPersonnel] TO [MssExec]
GO
Uses
Used By