Tables [dbo].[MilitaryBasePhoneNumber]
Properties
PropertyValue
CollationSQL_Latin1_General_CP1_CI_AS
HeapYes
Row Count (~)0
Created4:57:09 PM Thursday, September 7, 2006
Last Modified11:13:40 AM Monday, August 19, 2013
Columns
NameData TypeMax Length (Bytes)Allow NullsIdentity
Primary Key PK_MilitaryBasePhoneNumber: MilitaryBasePhoneNumberIDMilitaryBasePhoneNumberIDint4
No
1 - 1
Foreign Keys FK_MilitaryBasePhoneNumber_CountryCodeStandard: [dbo].[CountryCodeStandard].CountryCodeStandardFIDCountryCodeStandardFIDint4
Yes
AreaCode[dbo].[PhoneAreaCode]4
Yes
LocalNumber[dbo].[PhoneLocalNumber]20
Yes
Extension[dbo].[PhoneExtension]10
Yes
Foreign Keys FK_MilitaryBasePhoneNumber_MilitaryBase: [dbo].[MilitaryBase].MilitaryBaseFIDIndexes IX_MilitaryBasePhoneNumber_MilitaryBaseAndPhoneType: MilitaryBaseFID\MilitaryBasePhoneTypeFIDMilitaryBaseFIDint4
No
Foreign Keys FK_MilitaryBasePhoneNumber_MilitaryBasePhoneType: [dbo].[MilitaryBasePhoneType].MilitaryBasePhoneTypeFIDIndexes IX_MilitaryBasePhoneNumber_MilitaryBaseAndPhoneType: MilitaryBaseFID\MilitaryBasePhoneTypeFIDMilitaryBasePhoneTypeFIDint4
No
Indexes Indexes
NameColumnsUniqueFill Factor
Primary Key PK_MilitaryBasePhoneNumber: MilitaryBasePhoneNumberIDPK_MilitaryBasePhoneNumberMilitaryBasePhoneNumberID
Yes
80
IX_MilitaryBasePhoneNumber_MilitaryBaseAndPhoneTypeMilitaryBaseFID, MilitaryBasePhoneTypeFID
Yes
80
Foreign Keys Foreign Keys
NameDeleteColumns
FK_MilitaryBasePhoneNumber_CountryCodeStandardCountryCodeStandardFID->[dbo].[CountryCodeStandard].[CountryCodeStandardID]
FK_MilitaryBasePhoneNumber_MilitaryBaseCascadeMilitaryBaseFID->[dbo].[MilitaryBase].[MilitaryBaseID]
FK_MilitaryBasePhoneNumber_MilitaryBasePhoneTypeMilitaryBasePhoneTypeFID->[dbo].[MilitaryBasePhoneType].[MilitaryBasePhoneTypeID]
Permissions
TypeActionOwning Principal
GrantDeleteMssExec
GrantInsertMssExec
GrantSelectMssExec
GrantUpdateMssExec
SQL Script
CREATE TABLE [dbo].[MilitaryBasePhoneNumber]
(
[MilitaryBasePhoneNumberID] [int] NOT NULL IDENTITY(1, 1),
[CountryCodeStandardFID] [int] NULL,
[AreaCode] [dbo].[PhoneAreaCode] NULL,
[LocalNumber] [dbo].[PhoneLocalNumber] NULL,
[Extension] [dbo].[PhoneExtension] NULL,
[MilitaryBaseFID] [int] NOT NULL,
[MilitaryBasePhoneTypeFID] [int] NOT NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[MilitaryBasePhoneNumber] ADD CONSTRAINT [PK_MilitaryBasePhoneNumber] PRIMARY KEY NONCLUSTERED  ([MilitaryBasePhoneNumberID]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
ALTER TABLE [dbo].[MilitaryBasePhoneNumber] ADD CONSTRAINT [IX_MilitaryBasePhoneNumber_MilitaryBaseAndPhoneType] UNIQUE NONCLUSTERED  ([MilitaryBaseFID], [MilitaryBasePhoneTypeFID]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
ALTER TABLE [dbo].[MilitaryBasePhoneNumber] ADD CONSTRAINT [FK_MilitaryBasePhoneNumber_CountryCodeStandard] FOREIGN KEY ([CountryCodeStandardFID]) REFERENCES [dbo].[CountryCodeStandard] ([CountryCodeStandardID])
GO
ALTER TABLE [dbo].[MilitaryBasePhoneNumber] ADD CONSTRAINT [FK_MilitaryBasePhoneNumber_MilitaryBase] FOREIGN KEY ([MilitaryBaseFID]) REFERENCES [dbo].[MilitaryBase] ([MilitaryBaseID]) ON DELETE CASCADE
GO
ALTER TABLE [dbo].[MilitaryBasePhoneNumber] ADD CONSTRAINT [FK_MilitaryBasePhoneNumber_MilitaryBasePhoneType] FOREIGN KEY ([MilitaryBasePhoneTypeFID]) REFERENCES [dbo].[MilitaryBasePhoneType] ([MilitaryBasePhoneTypeID])
GO
GRANT SELECT ON  [dbo].[MilitaryBasePhoneNumber] TO [MssExec]
GRANT INSERT ON  [dbo].[MilitaryBasePhoneNumber] TO [MssExec]
GRANT DELETE ON  [dbo].[MilitaryBasePhoneNumber] TO [MssExec]
GRANT UPDATE ON  [dbo].[MilitaryBasePhoneNumber] TO [MssExec]
GO
Uses