Tables [dbo].[LaborType]
Properties
PropertyValue
CollationSQL_Latin1_General_CP1_CI_AS
Row Count (~)27
Created4:57:07 PM Thursday, September 7, 2006
Last Modified9:20:11 AM Friday, November 8, 2024
Columns
NameData TypeMax Length (Bytes)Allow NullsIdentityDefault
Cluster Primary Key PK_LaborType: PriKeyPriKeyint4
No
1 - 1
Indexes IX_LaborType_LaborType: LaborTypeLaborTypevarchar(20)20
No
IsLocalDispatchvarchar(1)1
Yes
Foreign Keys FK_LaborType_ItemCode: [dbo].[ItemCode].LaborICPriKeyLaborICPriKeyint4
Yes
GLNumbervarchar(10)10
Yes
IsLongDistancebit1
No
((0))
AverageHourlyWagedecimal(14,4)9
Yes
IsSystemTypebit1
No
((0))
IsSalesTeamTypebit1
No
((0))
Foreign Keys FK_LaborType_CapacityBucket: [dbo].[CapacityBucket].CapacityBucketFIDIndexes IX_LaborType_CapacityBucketFID: CapacityBucketFIDCapacityBucketFIDint4
Yes
Inactivebit1
No
((0))
Indexes Indexes
NameColumnsUniqueFill Factor
Cluster Primary Key PK_LaborType: PriKeyPK_LaborTypePriKey
Yes
80
IX_LaborType_LaborTypeLaborType
Yes
IX_LaborType_CapacityBucketFIDCapacityBucketFID
Foreign Keys Foreign Keys
NameColumns
FK_LaborType_CapacityBucketCapacityBucketFID->[dbo].[CapacityBucket].[CapacityBucketID]
FK_LaborType_ItemCodeLaborICPriKey->[dbo].[ItemCode].[ICPriKey]
Permissions
TypeActionOwning Principal
GrantDeleteMssExec
GrantInsertMssExec
GrantSelectMssExec
GrantUpdateMssExec
SQL Script
CREATE TABLE [dbo].[LaborType]
(
[PriKey] [int] NOT NULL IDENTITY(1, 1),
[LaborType] [varchar] (20) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[IsLocalDispatch] [varchar] (1) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[LaborICPriKey] [int] NULL,
[GLNumber] [varchar] (10) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[IsLongDistance] [bit] NOT NULL CONSTRAINT [DF_LaborType_IsLongDistance] DEFAULT ((0)),
[AverageHourlyWage] [decimal] (14, 4) NULL,
[IsSystemType] [bit] NOT NULL CONSTRAINT [DF_LaborType_IsSystemType] DEFAULT ((0)),
[IsSalesTeamType] [bit] NOT NULL CONSTRAINT [DF_LaborType_IsSaleTeamType] DEFAULT ((0)),
[CapacityBucketFID] [int] NULL,
[Inactive] [bit] NOT NULL CONSTRAINT [DF_LaborType_Inactive] DEFAULT ((0))
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[LaborType] ADD CONSTRAINT [PK_LaborType] PRIMARY KEY CLUSTERED  ([PriKey]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
CREATE NONCLUSTERED INDEX [IX_LaborType_CapacityBucketFID] ON [dbo].[LaborType] ([CapacityBucketFID]) ON [PRIMARY]
GO
CREATE UNIQUE NONCLUSTERED INDEX [IX_LaborType_LaborType] ON [dbo].[LaborType] ([LaborType]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[LaborType] ADD CONSTRAINT [FK_LaborType_CapacityBucket] FOREIGN KEY ([CapacityBucketFID]) REFERENCES [dbo].[CapacityBucket] ([CapacityBucketID])
GO
ALTER TABLE [dbo].[LaborType] ADD CONSTRAINT [FK_LaborType_ItemCode] FOREIGN KEY ([LaborICPriKey]) REFERENCES [dbo].[ItemCode] ([ICPriKey])
GO
GRANT SELECT ON  [dbo].[LaborType] TO [MssExec]
GRANT INSERT ON  [dbo].[LaborType] TO [MssExec]
GRANT DELETE ON  [dbo].[LaborType] TO [MssExec]
GRANT UPDATE ON  [dbo].[LaborType] TO [MssExec]
GO
Uses
Used By