Tables [dbo].[LaborTypeBranch]
Properties
PropertyValue
Row Count (~)0
Created7:29:57 PM Tuesday, September 24, 2024
Last Modified7:29:57 PM Tuesday, September 24, 2024
Columns
NameData TypeMax Length (Bytes)Allow NullsIdentity
Cluster Primary Key PK_LaborTypeBranch: LaborTypeBranchIDLaborTypeBranchIDint4
No
1 - 1
Foreign Keys FK_LaborTypeBranch_LaborType: [dbo].[LaborType].LaborTypeFIDIndexes IX_LaborTypeBranch_LaborType_Branch: LaborTypeFID\BranchFIDLaborTypeFIDint4
No
Foreign Keys FK_LaborTypeBranch_Branch: [dbo].[Branch].BranchFIDIndexes IX_LaborTypeBranch_Branch: BranchFIDIndexes IX_LaborTypeBranch_LaborType_Branch: LaborTypeFID\BranchFIDBranchFIDint4
No
AverageHourlyWagedecimal(14,4)9
No
Indexes Indexes
NameColumnsUnique
Cluster Primary Key PK_LaborTypeBranch: LaborTypeBranchIDPK_LaborTypeBranchLaborTypeBranchID
Yes
IX_LaborTypeBranch_LaborType_BranchLaborTypeFID, BranchFID
Yes
IX_LaborTypeBranch_BranchBranchFID
Foreign Keys Foreign Keys
NameColumns
FK_LaborTypeBranch_BranchBranchFID->[dbo].[Branch].[BranchPriKey]
FK_LaborTypeBranch_LaborTypeLaborTypeFID->[dbo].[LaborType].[PriKey]
Permissions
TypeActionOwning Principal
GrantDeleteMssExec
GrantInsertMssExec
GrantSelectMssExec
GrantUpdateMssExec
SQL Script
CREATE TABLE [dbo].[LaborTypeBranch]
(
[LaborTypeBranchID] [int] NOT NULL IDENTITY(1, 1),
[LaborTypeFID] [int] NOT NULL,
[BranchFID] [int] NOT NULL,
[AverageHourlyWage] [decimal] (14, 4) NOT NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[LaborTypeBranch] ADD CONSTRAINT [PK_LaborTypeBranch] PRIMARY KEY CLUSTERED  ([LaborTypeBranchID]) ON [PRIMARY]
GO
CREATE NONCLUSTERED INDEX [IX_LaborTypeBranch_Branch] ON [dbo].[LaborTypeBranch] ([BranchFID]) ON [PRIMARY]
GO
CREATE UNIQUE NONCLUSTERED INDEX [IX_LaborTypeBranch_LaborType_Branch] ON [dbo].[LaborTypeBranch] ([LaborTypeFID], [BranchFID]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[LaborTypeBranch] ADD CONSTRAINT [FK_LaborTypeBranch_Branch] FOREIGN KEY ([BranchFID]) REFERENCES [dbo].[Branch] ([BranchPriKey])
GO
ALTER TABLE [dbo].[LaborTypeBranch] ADD CONSTRAINT [FK_LaborTypeBranch_LaborType] FOREIGN KEY ([LaborTypeFID]) REFERENCES [dbo].[LaborType] ([PriKey])
GO
GRANT SELECT ON  [dbo].[LaborTypeBranch] TO [MssExec]
GRANT INSERT ON  [dbo].[LaborTypeBranch] TO [MssExec]
GRANT DELETE ON  [dbo].[LaborTypeBranch] TO [MssExec]
GRANT UPDATE ON  [dbo].[LaborTypeBranch] TO [MssExec]
GO
Uses