Tables [dbo].[CustomerNoteDetail]
Properties
PropertyValue
CollationSQL_Latin1_General_CP1_CI_AS
Row Count (~)0
Created7:07:56 PM Thursday, December 17, 2009
Last Modified3:46:14 PM Tuesday, November 18, 2014
Columns
NameData TypeMax Length (Bytes)Allow NullsIdentity
Cluster Primary Key PK_CustomerNoteDetail: CustomerNoteDetailIDCustomerNoteDetailIDint4
No
1 - 1
Foreign Keys FK_CustomerNoteDetail_CustomerNoteHeader: [dbo].[CustomerNoteHeader].CustomerNoteHeaderFIDIndexes IX_CustomerNoteDetail_CustomerNoteHeaderFID: CustomerNoteHeaderFIDCustomerNoteHeaderFIDint4
No
CreatedDatedatetime8
No
Foreign Keys FK_CustomerNoteDetail_Sysuser: [dbo].[Sysuser].CreatedByFIDIndexes IX_CustomerNoteDetail_CreatedByFID: CreatedByFIDCreatedByFIDint4
No
NoteBodytextmax
No
PublicFlagbit1
No
Indexes Indexes
NameColumnsUniqueFill Factor
Cluster Primary Key PK_CustomerNoteDetail: CustomerNoteDetailIDPK_CustomerNoteDetailCustomerNoteDetailID
Yes
80
IX_CustomerNoteDetail_CreatedByFIDCreatedByFID
IX_CustomerNoteDetail_CustomerNoteHeaderFIDCustomerNoteHeaderFID80
Foreign Keys Foreign Keys
NameColumns
FK_CustomerNoteDetail_SysuserCreatedByFID->[dbo].[Sysuser].[SysUserID]
FK_CustomerNoteDetail_CustomerNoteHeaderCustomerNoteHeaderFID->[dbo].[CustomerNoteHeader].[CustomerNoteHeaderID]
Permissions
TypeActionOwning Principal
GrantDeleteMssExec
GrantInsertMssExec
GrantSelectMssExec
GrantUpdateMssExec
SQL Script
CREATE TABLE [dbo].[CustomerNoteDetail]
(
[CustomerNoteDetailID] [int] NOT NULL IDENTITY(1, 1),
[CustomerNoteHeaderFID] [int] NOT NULL,
[CreatedDate] [datetime] NOT NULL,
[CreatedByFID] [int] NOT NULL,
[NoteBody] [text] COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[PublicFlag] [bit] NOT NULL
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO
ALTER TABLE [dbo].[CustomerNoteDetail] ADD CONSTRAINT [PK_CustomerNoteDetail] PRIMARY KEY CLUSTERED  ([CustomerNoteDetailID]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
CREATE NONCLUSTERED INDEX [IX_CustomerNoteDetail_CreatedByFID] ON [dbo].[CustomerNoteDetail] ([CreatedByFID]) ON [PRIMARY]
GO
CREATE NONCLUSTERED INDEX [IX_CustomerNoteDetail_CustomerNoteHeaderFID] ON [dbo].[CustomerNoteDetail] ([CustomerNoteHeaderFID]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
ALTER TABLE [dbo].[CustomerNoteDetail] ADD CONSTRAINT [FK_CustomerNoteDetail_Sysuser] FOREIGN KEY ([CreatedByFID]) REFERENCES [dbo].[Sysuser] ([SysUserID])
GO
ALTER TABLE [dbo].[CustomerNoteDetail] ADD CONSTRAINT [FK_CustomerNoteDetail_CustomerNoteHeader] FOREIGN KEY ([CustomerNoteHeaderFID]) REFERENCES [dbo].[CustomerNoteHeader] ([CustomerNoteHeaderID])
GO
GRANT SELECT ON  [dbo].[CustomerNoteDetail] TO [MssExec]
GRANT INSERT ON  [dbo].[CustomerNoteDetail] TO [MssExec]
GRANT DELETE ON  [dbo].[CustomerNoteDetail] TO [MssExec]
GRANT UPDATE ON  [dbo].[CustomerNoteDetail] TO [MssExec]
GO
Uses