Tables [dbo].[ReductionTemplateItemCodeMap]
Properties
PropertyValue
HeapYes
Row Count (~)252
Created4:49:42 PM Tuesday, June 19, 2012
Last Modified11:13:41 AM Monday, August 19, 2013
Columns
NameData TypeMax Length (Bytes)Allow NullsIdentity
Primary Key PK_ReductionTemplateItemCodeMap: ReductionTemplateItemCodeMapIDReductionTemplateItemCodeMapIDint4
No
1 - 1
Foreign Keys FK_ReductionTemplateItemCodeMap_ReductionTemplateHeader: [dbo].[ReductionTemplateHeader].ReductionTemplateHeaderFIDIndexes IX_ReductionTemplateItemCodeMap_HeaderItemCode: ReductionTemplateHeaderFID\ItemCodeFIDReductionTemplateHeaderFIDint4
No
Foreign Keys FK_ReductionTemplateItemCodeMap_ItemCode: [dbo].[ItemCode].ItemCodeFIDIndexes IX_ReductionTemplateItemCodeMap_HeaderItemCode: ReductionTemplateHeaderFID\ItemCodeFIDItemCodeFIDint4
No
Indexes Indexes
NameColumnsUnique
Primary Key PK_ReductionTemplateItemCodeMap: ReductionTemplateItemCodeMapIDPK_ReductionTemplateItemCodeMapReductionTemplateItemCodeMapID
Yes
IX_ReductionTemplateItemCodeMap_HeaderItemCodeReductionTemplateHeaderFID, ItemCodeFID
Yes
Foreign Keys Foreign Keys
NameColumns
FK_ReductionTemplateItemCodeMap_ItemCodeItemCodeFID->[dbo].[ItemCode].[ICPriKey]
FK_ReductionTemplateItemCodeMap_ReductionTemplateHeaderReductionTemplateHeaderFID->[dbo].[ReductionTemplateHeader].[ReductionTemplateID]
Permissions
TypeActionOwning Principal
GrantDeleteMssExec
GrantInsertMssExec
GrantSelectMssExec
GrantUpdateMssExec
SQL Script
CREATE TABLE [dbo].[ReductionTemplateItemCodeMap]
(
[ReductionTemplateItemCodeMapID] [int] NOT NULL IDENTITY(1, 1),
[ReductionTemplateHeaderFID] [int] NOT NULL,
[ItemCodeFID] [int] NOT NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[ReductionTemplateItemCodeMap] ADD CONSTRAINT [PK_ReductionTemplateItemCodeMap] PRIMARY KEY NONCLUSTERED  ([ReductionTemplateItemCodeMapID]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[ReductionTemplateItemCodeMap] ADD CONSTRAINT [IX_ReductionTemplateItemCodeMap_HeaderItemCode] UNIQUE NONCLUSTERED  ([ReductionTemplateHeaderFID], [ItemCodeFID]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[ReductionTemplateItemCodeMap] ADD CONSTRAINT [FK_ReductionTemplateItemCodeMap_ItemCode] FOREIGN KEY ([ItemCodeFID]) REFERENCES [dbo].[ItemCode] ([ICPriKey])
GO
ALTER TABLE [dbo].[ReductionTemplateItemCodeMap] ADD CONSTRAINT [FK_ReductionTemplateItemCodeMap_ReductionTemplateHeader] FOREIGN KEY ([ReductionTemplateHeaderFID]) REFERENCES [dbo].[ReductionTemplateHeader] ([ReductionTemplateID])
GO
GRANT SELECT ON  [dbo].[ReductionTemplateItemCodeMap] TO [MssExec]
GRANT INSERT ON  [dbo].[ReductionTemplateItemCodeMap] TO [MssExec]
GRANT DELETE ON  [dbo].[ReductionTemplateItemCodeMap] TO [MssExec]
GRANT UPDATE ON  [dbo].[ReductionTemplateItemCodeMap] TO [MssExec]
GO
Uses