Tables [dbo].[DocumentAutoDownloadRuleDetailBranch]
Properties
PropertyValue
Row Count (~)0
Created8:52:58 AM Thursday, December 5, 2024
Last Modified8:52:58 AM Thursday, December 5, 2024
Columns
NameData TypeMax Length (Bytes)Allow NullsIdentity
Cluster Primary Key PK_DocumentAutoDownloadRuleDetailBranch: DocumentAutoDownloadRuleDetailBranchIDDocumentAutoDownloadRuleDetailBranchIDint4
No
1 - 1
Foreign Keys FK_DocumentAutoDownloadRuleDetailBranch_DocumentAutoDownloadRuleDetail: [dbo].[DocumentAutoDownloadRuleDetail].DocumentAutoDownloadRuleDetailFIDIndexes IX_DocumentAutoDownloadRuleDetailBranch_RuleDetail: DocumentAutoDownloadRuleDetailFID\BranchFIDDocumentAutoDownloadRuleDetailFIDint4
No
Foreign Keys FK_DocumentAutoDownloadRuleDetailBranch_Branch: [dbo].[Branch].BranchFIDIndexes IX_DocumentAutoDownloadRuleDetailBranch_Branch: BranchFIDIndexes IX_DocumentAutoDownloadRuleDetailBranch_RuleDetail: DocumentAutoDownloadRuleDetailFID\BranchFIDBranchFIDint4
No
Indexes Indexes
NameColumnsUnique
Cluster Primary Key PK_DocumentAutoDownloadRuleDetailBranch: DocumentAutoDownloadRuleDetailBranchIDPK_DocumentAutoDownloadRuleDetailBranchDocumentAutoDownloadRuleDetailBranchID
Yes
IX_DocumentAutoDownloadRuleDetailBranch_RuleDetailDocumentAutoDownloadRuleDetailFID, BranchFID
Yes
IX_DocumentAutoDownloadRuleDetailBranch_BranchBranchFID
Foreign Keys Foreign Keys
NameDeleteColumns
FK_DocumentAutoDownloadRuleDetailBranch_BranchCascadeBranchFID->[dbo].[Branch].[BranchPriKey]
FK_DocumentAutoDownloadRuleDetailBranch_DocumentAutoDownloadRuleDetailCascadeDocumentAutoDownloadRuleDetailFID->[dbo].[DocumentAutoDownloadRuleDetail].[DocumentAutoDownloadRuleDetailID]
Permissions
TypeActionOwning Principal
GrantDeleteMssExec
GrantInsertMssExec
GrantSelectMssExec
GrantUpdateMssExec
SQL Script
CREATE TABLE [dbo].[DocumentAutoDownloadRuleDetailBranch]
(
[DocumentAutoDownloadRuleDetailBranchID] [int] NOT NULL IDENTITY(1, 1),
[DocumentAutoDownloadRuleDetailFID] [int] NOT NULL,
[BranchFID] [int] NOT NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[DocumentAutoDownloadRuleDetailBranch] ADD CONSTRAINT [PK_DocumentAutoDownloadRuleDetailBranch] PRIMARY KEY CLUSTERED  ([DocumentAutoDownloadRuleDetailBranchID]) ON [PRIMARY]
GO
CREATE NONCLUSTERED INDEX [IX_DocumentAutoDownloadRuleDetailBranch_Branch] ON [dbo].[DocumentAutoDownloadRuleDetailBranch] ([BranchFID]) ON [PRIMARY]
GO
CREATE UNIQUE NONCLUSTERED INDEX [IX_DocumentAutoDownloadRuleDetailBranch_RuleDetail] ON [dbo].[DocumentAutoDownloadRuleDetailBranch] ([DocumentAutoDownloadRuleDetailFID], [BranchFID]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[DocumentAutoDownloadRuleDetailBranch] ADD CONSTRAINT [FK_DocumentAutoDownloadRuleDetailBranch_Branch] FOREIGN KEY ([BranchFID]) REFERENCES [dbo].[Branch] ([BranchPriKey]) ON DELETE CASCADE
GO
ALTER TABLE [dbo].[DocumentAutoDownloadRuleDetailBranch] ADD CONSTRAINT [FK_DocumentAutoDownloadRuleDetailBranch_DocumentAutoDownloadRuleDetail] FOREIGN KEY ([DocumentAutoDownloadRuleDetailFID]) REFERENCES [dbo].[DocumentAutoDownloadRuleDetail] ([DocumentAutoDownloadRuleDetailID]) ON DELETE CASCADE
GO
GRANT SELECT ON  [dbo].[DocumentAutoDownloadRuleDetailBranch] TO [MssExec]
GRANT INSERT ON  [dbo].[DocumentAutoDownloadRuleDetailBranch] TO [MssExec]
GRANT DELETE ON  [dbo].[DocumentAutoDownloadRuleDetailBranch] TO [MssExec]
GRANT UPDATE ON  [dbo].[DocumentAutoDownloadRuleDetailBranch] TO [MssExec]
GO
Uses