Tables [dbo].[SysUserPhoneNumber]
Properties
PropertyValue
CollationSQL_Latin1_General_CP1_CI_AS
HeapYes
Row Count (~)54
Created4:57:08 PM Thursday, September 7, 2006
Last Modified12:32:37 PM Monday, August 4, 2014
Columns
NameData TypeMax Length (Bytes)Allow NullsIdentity
Primary Key PK_SysUserPhoneNumber: SysUserPhoneNumberIDSysUserPhoneNumberIDint4
No
1 - 1
Foreign Keys FK_SysUserPhoneNumber_CountryCodeStandard: [dbo].[CountryCodeStandard].CountryCodeStandardFIDCountryCodeStandardFIDint4
Yes
AreaCode[dbo].[PhoneAreaCode]4
Yes
LocalNumber[dbo].[PhoneLocalNumber]20
Yes
Extension[dbo].[PhoneExtension]10
Yes
Foreign Keys FK_SysUserPhoneNumber_SysUser: [dbo].[Sysuser].SysUserFIDIndexes IX_SysUserPhoneNumber_SysUserAndPhoneType: SysUserFID\SysUserPhoneTypeFIDSysUserFIDint4
No
Foreign Keys FK_SysUserPhoneNumber_SysUserPhoneType: [dbo].[SysUserPhoneType].SysUserPhoneTypeFIDIndexes IX_SysUserPhoneNumber_SysUserAndPhoneType: SysUserFID\SysUserPhoneTypeFIDSysUserPhoneTypeFIDint4
No
Indexes Indexes
NameColumnsUniqueFill Factor
Primary Key PK_SysUserPhoneNumber: SysUserPhoneNumberIDPK_SysUserPhoneNumberSysUserPhoneNumberID
Yes
80
IX_SysUserPhoneNumber_SysUserAndPhoneTypeSysUserFID, SysUserPhoneTypeFID
Yes
80
Foreign Keys Foreign Keys
NameDeleteColumns
FK_SysUserPhoneNumber_CountryCodeStandardCountryCodeStandardFID->[dbo].[CountryCodeStandard].[CountryCodeStandardID]
FK_SysUserPhoneNumber_SysUserCascadeSysUserFID->[dbo].[Sysuser].[SysUserID]
FK_SysUserPhoneNumber_SysUserPhoneTypeSysUserPhoneTypeFID->[dbo].[SysUserPhoneType].[SysUserPhoneTypeID]
Permissions
TypeActionOwning Principal
GrantDeleteMssExec
GrantInsertMssExec
GrantSelectMssExec
GrantUpdateMssExec
SQL Script
CREATE TABLE [dbo].[SysUserPhoneNumber]
(
[SysUserPhoneNumberID] [int] NOT NULL IDENTITY(1, 1),
[CountryCodeStandardFID] [int] NULL,
[AreaCode] [dbo].[PhoneAreaCode] NULL,
[LocalNumber] [dbo].[PhoneLocalNumber] NULL,
[Extension] [dbo].[PhoneExtension] NULL,
[SysUserFID] [int] NOT NULL,
[SysUserPhoneTypeFID] [int] NOT NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[SysUserPhoneNumber] ADD CONSTRAINT [PK_SysUserPhoneNumber] PRIMARY KEY NONCLUSTERED  ([SysUserPhoneNumberID]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
ALTER TABLE [dbo].[SysUserPhoneNumber] ADD CONSTRAINT [IX_SysUserPhoneNumber_SysUserAndPhoneType] UNIQUE NONCLUSTERED  ([SysUserFID], [SysUserPhoneTypeFID]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
ALTER TABLE [dbo].[SysUserPhoneNumber] ADD CONSTRAINT [FK_SysUserPhoneNumber_CountryCodeStandard] FOREIGN KEY ([CountryCodeStandardFID]) REFERENCES [dbo].[CountryCodeStandard] ([CountryCodeStandardID])
GO
ALTER TABLE [dbo].[SysUserPhoneNumber] ADD CONSTRAINT [FK_SysUserPhoneNumber_SysUser] FOREIGN KEY ([SysUserFID]) REFERENCES [dbo].[Sysuser] ([SysUserID]) ON DELETE CASCADE
GO
ALTER TABLE [dbo].[SysUserPhoneNumber] ADD CONSTRAINT [FK_SysUserPhoneNumber_SysUserPhoneType] FOREIGN KEY ([SysUserPhoneTypeFID]) REFERENCES [dbo].[SysUserPhoneType] ([SysUserPhoneTypeID])
GO
GRANT SELECT ON  [dbo].[SysUserPhoneNumber] TO [MssExec]
GRANT INSERT ON  [dbo].[SysUserPhoneNumber] TO [MssExec]
GRANT DELETE ON  [dbo].[SysUserPhoneNumber] TO [MssExec]
GRANT UPDATE ON  [dbo].[SysUserPhoneNumber] TO [MssExec]
GO
Uses
Used By