Tables [dbo].[OrdersExtended]
Properties
PropertyValue
CollationSQL_Latin1_General_CP1_CI_AS
Row Count (~)0
Created10:03:28 AM Friday, December 7, 2018
Last Modified10:03:47 AM Friday, December 7, 2018
Columns
NameData TypeMax Length (Bytes)Allow NullsIdentity
Cluster Primary Key PK_OrdersExtended: OrdersExtendedIDOrdersExtendedIDint4
No
1 - 1
Foreign Keys FK_OrdersExtended_Order: [dbo].[Orders].OrderFIDIndexes IX_OrdersExtended_Order: OrderFIDOrderFIDint4
No
Foreign Keys FK_OrdersExtended_CommodityDetail: [dbo].[CommodityDetail].CommodityDetailFIDCommodityDetailFIDint4
Yes
Foreign Keys FK_OrdersExtended_HaulMode: [dbo].[HaulMode].HaulModeFIDHaulModeFIDint4
Yes
WillAdvisevarchar(1)1
Yes
CodCollectionAmountmoney8
Yes
Indexes Indexes
NameColumnsUnique
Cluster Primary Key PK_OrdersExtended: OrdersExtendedIDPK_OrdersExtendedOrdersExtendedID
Yes
IX_OrdersExtended_OrderOrderFID
Yes
Foreign Keys Foreign Keys
NameColumns
FK_OrdersExtended_CommodityDetailCommodityDetailFID->[dbo].[CommodityDetail].[CommodityDetailID]
FK_OrdersExtended_HaulModeHaulModeFID->[dbo].[HaulMode].[HaulModeID]
FK_OrdersExtended_OrderOrderFID->[dbo].[Orders].[PriKey]
Permissions
TypeActionOwning Principal
GrantDeleteMssExec
GrantInsertMssExec
GrantSelectMssExec
GrantUpdateMssExec
SQL Script
CREATE TABLE [dbo].[OrdersExtended]
(
[OrdersExtendedID] [int] NOT NULL IDENTITY(1, 1),
[OrderFID] [int] NOT NULL,
[CommodityDetailFID] [int] NULL,
[HaulModeFID] [int] NULL,
[WillAdvise] [varchar] (1) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[CodCollectionAmount] [money] NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[OrdersExtended] ADD CONSTRAINT [PK_OrdersExtended] PRIMARY KEY CLUSTERED  ([OrdersExtendedID]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[OrdersExtended] ADD CONSTRAINT [IX_OrdersExtended_Order] UNIQUE NONCLUSTERED  ([OrderFID]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[OrdersExtended] ADD CONSTRAINT [FK_OrdersExtended_CommodityDetail] FOREIGN KEY ([CommodityDetailFID]) REFERENCES [dbo].[CommodityDetail] ([CommodityDetailID])
GO
ALTER TABLE [dbo].[OrdersExtended] ADD CONSTRAINT [FK_OrdersExtended_HaulMode] FOREIGN KEY ([HaulModeFID]) REFERENCES [dbo].[HaulMode] ([HaulModeID])
GO
ALTER TABLE [dbo].[OrdersExtended] ADD CONSTRAINT [FK_OrdersExtended_Order] FOREIGN KEY ([OrderFID]) REFERENCES [dbo].[Orders] ([PriKey])
GO
GRANT SELECT ON  [dbo].[OrdersExtended] TO [MssExec]
GRANT INSERT ON  [dbo].[OrdersExtended] TO [MssExec]
GRANT DELETE ON  [dbo].[OrdersExtended] TO [MssExec]
GRANT UPDATE ON  [dbo].[OrdersExtended] TO [MssExec]
GO
Uses
Used By