Tables [dbo].[SysuserBranch]
Properties
PropertyValue
Row Count (~)2235
Created4:57:08 PM Thursday, September 7, 2006
Last Modified12:32:37 PM Monday, August 4, 2014
Columns
NameData TypeMax Length (Bytes)Allow NullsIdentityDefault
Cluster Primary Key PK_SysuserBranch: SysuserBranchPriKeyIndexes IX_SysUserBranch_SysUser: BranchPriKey\SysuserPriKey\SysuserBranchPriKeyStatistics STATS_SysUserBranch_SysUser_2: BranchPriKey\SysuserBranchPriKeyStatistics STATS_SysUserBranch_SysUser_1: BranchPriKey\SysuserBranchPriKey\SysuserPriKeySysuserBranchPriKeyint4
No
1 - 1
Foreign Keys FK_SysuserBranch_Sysuser: [dbo].[Sysuser].SysuserPriKeyCheck Constraints CK_SysuserBranch_DefaultBranch : ((1)<>[dbo].[CheckDuplicateDefaultBranches]([SysuserPriKey]))Indexes IX_SysUserBranch_SysUser: BranchPriKey\SysuserPriKey\SysuserBranchPriKeyIndexes IX_SysuserBranch_SysUserPriKey: SysuserPriKeyStatistics STATS_SysUserBranch_SysUser_1: BranchPriKey\SysuserBranchPriKey\SysuserPriKeySysuserPriKeyint4
No
Foreign Keys FK_SysuserBranch_Branch: [dbo].[Branch].BranchPriKeyIndexes IX_SysuserBranch_BranchPrikey: BranchPriKeyIndexes IX_SysUserBranch_SysUser: BranchPriKey\SysuserPriKey\SysuserBranchPriKeyStatistics STATS_SysUserBranch_SysUser_2: BranchPriKey\SysuserBranchPriKeyStatistics STATS_SysUserBranch_SysUser_1: BranchPriKey\SysuserBranchPriKey\SysuserPriKeyBranchPriKeyint4
No
DefaultBranchsmallint2
No
(1)
Indexes Indexes
NameColumnsUniqueFill Factor
Cluster Primary Key PK_SysuserBranch: SysuserBranchPriKeyPK_SysuserBranchSysuserBranchPriKey
Yes
80
IX_SysuserBranch_BranchPrikeyBranchPriKey80
IX_SysUserBranch_SysUserBranchPriKey, SysuserPriKey, SysuserBranchPriKey80
IX_SysuserBranch_SysUserPriKeySysuserPriKey80
Statistics Statistics
NameColumns
STATS_SysUserBranch_SysUser_1BranchPriKey, SysuserBranchPriKey, SysuserPriKey
STATS_SysUserBranch_SysUser_2BranchPriKey, SysuserBranchPriKey
Check Constraints Check Constraints
NameOn ColumnConstraint
CK_SysuserBranch_DefaultBranchSysuserPriKey((1)<>[dbo].[CheckDuplicateDefaultBranches]([SysuserPriKey]))
Foreign Keys Foreign Keys
NameColumns
FK_SysuserBranch_BranchBranchPriKey->[dbo].[Branch].[BranchPriKey]
FK_SysuserBranch_SysuserSysuserPriKey->[dbo].[Sysuser].[SysUserID]
Permissions
TypeActionOwning Principal
GrantDeleteMssExec
GrantInsertMssExec
GrantSelectMssExec
GrantUpdateMssExec
SQL Script
CREATE TABLE [dbo].[SysuserBranch]
(
[SysuserBranchPriKey] [int] NOT NULL IDENTITY(1, 1),
[SysuserPriKey] [int] NOT NULL,
[BranchPriKey] [int] NOT NULL,
[DefaultBranch] [smallint] NOT NULL CONSTRAINT [DF_SysuserBranch_DefaultBranch] DEFAULT (1)
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[SysuserBranch] ADD CONSTRAINT [CK_SysuserBranch_DefaultBranch] CHECK (((1)<>[dbo].[CheckDuplicateDefaultBranches]([SysuserPriKey])))
GO
ALTER TABLE [dbo].[SysuserBranch] ADD CONSTRAINT [PK_SysuserBranch] PRIMARY KEY CLUSTERED  ([SysuserBranchPriKey]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
CREATE NONCLUSTERED INDEX [IX_SysuserBranch_BranchPrikey] ON [dbo].[SysuserBranch] ([BranchPriKey]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
CREATE NONCLUSTERED INDEX [IX_SysUserBranch_SysUser] ON [dbo].[SysuserBranch] ([BranchPriKey], [SysuserPriKey], [SysuserBranchPriKey]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
CREATE NONCLUSTERED INDEX [IX_SysuserBranch_SysUserPriKey] ON [dbo].[SysuserBranch] ([SysuserPriKey]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
CREATE STATISTICS [STATS_SysUserBranch_SysUser_2] ON [dbo].[SysuserBranch] ([BranchPriKey], [SysuserBranchPriKey])
GO
CREATE STATISTICS [STATS_SysUserBranch_SysUser_1] ON [dbo].[SysuserBranch] ([BranchPriKey], [SysuserBranchPriKey], [SysuserPriKey])
GO
ALTER TABLE [dbo].[SysuserBranch] ADD CONSTRAINT [FK_SysuserBranch_Branch] FOREIGN KEY ([BranchPriKey]) REFERENCES [dbo].[Branch] ([BranchPriKey])
GO
ALTER TABLE [dbo].[SysuserBranch] ADD CONSTRAINT [FK_SysuserBranch_Sysuser] FOREIGN KEY ([SysuserPriKey]) REFERENCES [dbo].[Sysuser] ([SysUserID])
GO
GRANT SELECT ON  [dbo].[SysuserBranch] TO [MssExec]
GRANT INSERT ON  [dbo].[SysuserBranch] TO [MssExec]
GRANT DELETE ON  [dbo].[SysuserBranch] TO [MssExec]
GRANT UPDATE ON  [dbo].[SysuserBranch] TO [MssExec]
GO
Uses
Used By