Tables [dbo].[CustomerStatementInvoiceGroup]
Properties
PropertyValue
CollationSQL_Latin1_General_CP1_CI_AS
Row Count (~)73819
Created10:12:52 PM Thursday, December 28, 2006
Last Modified11:13:38 AM Monday, August 19, 2013
Columns
NameData TypeMax Length (Bytes)Allow NullsIdentityDefault
Primary Key PK_CustomerStatementInvoiceGroup: CustomerStatementInvoiceGroupIDCustomerStatementInvoiceGroupIDint4
No
1 - 1
Cluster Key IX_CustomerStatementInvoiceGroup_OrderGroupFID: CustomerStatementOrderGroupFIDForeign Keys FK_CustomerStatementInvoiceGroup_CustomerStatementOrderGroup: [dbo].[CustomerStatementOrderGroup].CustomerStatementOrderGroupFIDCustomerStatementOrderGroupFIDint4
No
Foreign Keys FK_CustomerStatementInvoiceGroup_CustomerStatementDocumentType: [dbo].[CustomerStatementDocumentType].CustomerStatementDocumentTypeFIDCustomerStatementDocumentTypeFIDint4
No
Indexes IX_CustomerStatementInvoiceGroup_InvoiceNumber: InvoiceNumberInvoiceNumbervarchar(31)31
No
Descriptionvarchar(128)128
No
InvoiceDatedatetime8
Yes
Amountmoney8
No
Statusvarchar(32)32
No
('')
Visiblebit1
No
((0))
Indexes Indexes
NameColumnsUniqueFill Factor
Primary Key PK_CustomerStatementInvoiceGroup: CustomerStatementInvoiceGroupIDPK_CustomerStatementInvoiceGroupCustomerStatementInvoiceGroupID
Yes
80
IX_CustomerStatementInvoiceGroup_InvoiceNumberInvoiceNumber80
Cluster Key IX_CustomerStatementInvoiceGroup_OrderGroupFID: CustomerStatementOrderGroupFIDIX_CustomerStatementInvoiceGroup_OrderGroupFIDCustomerStatementOrderGroupFID80
Foreign Keys Foreign Keys
NameDeleteColumns
FK_CustomerStatementInvoiceGroup_CustomerStatementDocumentTypeCustomerStatementDocumentTypeFID->[dbo].[CustomerStatementDocumentType].[CustomerStatementDocumentTypeID]
FK_CustomerStatementInvoiceGroup_CustomerStatementOrderGroupCascadeCustomerStatementOrderGroupFID->[dbo].[CustomerStatementOrderGroup].[CustomerStatementOrderGroupID]
Permissions
TypeActionOwning Principal
GrantDeleteMssExec
GrantInsertMssExec
GrantSelectMssExec
GrantUpdateMssExec
SQL Script
CREATE TABLE [dbo].[CustomerStatementInvoiceGroup]
(
[CustomerStatementInvoiceGroupID] [int] NOT NULL IDENTITY(1, 1),
[CustomerStatementOrderGroupFID] [int] NOT NULL,
[CustomerStatementDocumentTypeFID] [int] NOT NULL,
[InvoiceNumber] [varchar] (31) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[Description] [varchar] (128) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[InvoiceDate] [datetime] NULL,
[Amount] [money] NOT NULL,
[Status] [varchar] (32) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL CONSTRAINT [DF_CustomerStatementInvoiceGroup_Status] DEFAULT (''),
[Visible] [bit] NOT NULL CONSTRAINT [DF_CustomerStatementInvoiceGroup_Visible] DEFAULT ((0))
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[CustomerStatementInvoiceGroup] ADD CONSTRAINT [PK_CustomerStatementInvoiceGroup] PRIMARY KEY NONCLUSTERED  ([CustomerStatementInvoiceGroupID]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
CREATE CLUSTERED INDEX [IX_CustomerStatementInvoiceGroup_OrderGroupFID] ON [dbo].[CustomerStatementInvoiceGroup] ([CustomerStatementOrderGroupFID]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
CREATE NONCLUSTERED INDEX [IX_CustomerStatementInvoiceGroup_InvoiceNumber] ON [dbo].[CustomerStatementInvoiceGroup] ([InvoiceNumber]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
ALTER TABLE [dbo].[CustomerStatementInvoiceGroup] ADD CONSTRAINT [FK_CustomerStatementInvoiceGroup_CustomerStatementDocumentType] FOREIGN KEY ([CustomerStatementDocumentTypeFID]) REFERENCES [dbo].[CustomerStatementDocumentType] ([CustomerStatementDocumentTypeID])
GO
ALTER TABLE [dbo].[CustomerStatementInvoiceGroup] ADD CONSTRAINT [FK_CustomerStatementInvoiceGroup_CustomerStatementOrderGroup] FOREIGN KEY ([CustomerStatementOrderGroupFID]) REFERENCES [dbo].[CustomerStatementOrderGroup] ([CustomerStatementOrderGroupID]) ON DELETE CASCADE
GO
GRANT SELECT ON  [dbo].[CustomerStatementInvoiceGroup] TO [MssExec]
GRANT INSERT ON  [dbo].[CustomerStatementInvoiceGroup] TO [MssExec]
GRANT DELETE ON  [dbo].[CustomerStatementInvoiceGroup] TO [MssExec]
GRANT UPDATE ON  [dbo].[CustomerStatementInvoiceGroup] TO [MssExec]
GO
Uses
Used By