Tables [dbo].[CustomerStatementImage]
Properties
PropertyValue
Row Count (~)0
Created10:12:49 PM Thursday, December 28, 2006
Last Modified11:13:38 AM Monday, August 19, 2013
Columns
NameData TypeMax Length (Bytes)Allow NullsIdentity
Cluster Primary Key pk_CustomerStatementImage: CustomerStatementImageIDCustomerStatementImageIDint4
No
1 - 1
Foreign Keys FK_CustomerStatementImage_CustomerStatement: [dbo].[CustomerStatement].CustomerStatementFIDCustomerStatementFIDint4
No
CustomerStatementImageimagemax
No
Foreign Keys FK_CustomerStatementImage_ReportType: [dbo].[ReportType].ReportTypeFIDReportTypeFIDsmallint2
No
Foreign Keys FK_CustomerStatementImage_ReportArchiveType: [dbo].[ReportArchiveType].ReportArchiveTypeFIDReportArchiveTypeFIDint4
Yes
Indexes Indexes
NameColumnsUniqueFill Factor
Cluster Primary Key pk_CustomerStatementImage: CustomerStatementImageIDpk_CustomerStatementImageCustomerStatementImageID
Yes
80
Foreign Keys Foreign Keys
NameDeleteColumns
FK_CustomerStatementImage_CustomerStatementCascadeCustomerStatementFID->[dbo].[CustomerStatement].[CustomerStatementID]
FK_CustomerStatementImage_ReportArchiveTypeReportArchiveTypeFID->[dbo].[ReportArchiveType].[ReportArchiveTypeID]
FK_CustomerStatementImage_ReportTypeReportTypeFID->[dbo].[ReportType].[ReportTypeID]
Permissions
TypeActionOwning Principal
GrantDeleteMssExec
GrantInsertMssExec
GrantSelectMssExec
GrantUpdateMssExec
SQL Script
CREATE TABLE [dbo].[CustomerStatementImage]
(
[CustomerStatementImageID] [int] NOT NULL IDENTITY(1, 1),
[CustomerStatementFID] [int] NOT NULL,
[CustomerStatementImage] [image] NOT NULL,
[ReportTypeFID] [smallint] NOT NULL,
[ReportArchiveTypeFID] [int] NULL
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO
ALTER TABLE [dbo].[CustomerStatementImage] ADD CONSTRAINT [pk_CustomerStatementImage] PRIMARY KEY CLUSTERED  ([CustomerStatementImageID]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
ALTER TABLE [dbo].[CustomerStatementImage] ADD CONSTRAINT [FK_CustomerStatementImage_CustomerStatement] FOREIGN KEY ([CustomerStatementFID]) REFERENCES [dbo].[CustomerStatement] ([CustomerStatementID]) ON DELETE CASCADE
GO
ALTER TABLE [dbo].[CustomerStatementImage] ADD CONSTRAINT [FK_CustomerStatementImage_ReportArchiveType] FOREIGN KEY ([ReportArchiveTypeFID]) REFERENCES [dbo].[ReportArchiveType] ([ReportArchiveTypeID])
GO
ALTER TABLE [dbo].[CustomerStatementImage] ADD CONSTRAINT [FK_CustomerStatementImage_ReportType] FOREIGN KEY ([ReportTypeFID]) REFERENCES [dbo].[ReportType] ([ReportTypeID])
GO
GRANT SELECT ON  [dbo].[CustomerStatementImage] TO [MssExec]
GRANT INSERT ON  [dbo].[CustomerStatementImage] TO [MssExec]
GRANT DELETE ON  [dbo].[CustomerStatementImage] TO [MssExec]
GRANT UPDATE ON  [dbo].[CustomerStatementImage] TO [MssExec]
GO
Uses