• lsrep17 Documentation
  • Tables [Person].[PersonPhone]
    Telephone number and type of a person.
    PropertyValue
    CollationSQL_Latin1_General_CP1_CI_AS
    Row Count (~)19972
    Created13:14:19 14 marca 2012
    Last Modified13:14:54 14 marca 2012
    KeyNameData TypeMax Length (Bytes)Allow NullsDefaultDescription
    Cluster Primary Key PK_PersonPhone_BusinessEntityID_PhoneNumber_PhoneNumberTypeID: BusinessEntityID\PhoneNumber\PhoneNumberTypeIDForeign Keys FK_PersonPhone_Person_BusinessEntityID: [Person].[Person].BusinessEntityIDBusinessEntityIDint4
    False
    Business entity identification number. Foreign key to Person.BusinessEntityID.
    Cluster Primary Key PK_PersonPhone_BusinessEntityID_PhoneNumber_PhoneNumberTypeID: BusinessEntityID\PhoneNumber\PhoneNumberTypeIDIndexes IX_PersonPhone_PhoneNumberPhoneNumber[dbo].[Phone]50
    False
    Telephone number identification number.
    Cluster Primary Key PK_PersonPhone_BusinessEntityID_PhoneNumber_PhoneNumberTypeID: BusinessEntityID\PhoneNumber\PhoneNumberTypeIDForeign Keys FK_PersonPhone_PhoneNumberType_PhoneNumberTypeID: [Person].[PhoneNumberType].PhoneNumberTypeIDPhoneNumberTypeIDint4
    False
    Kind of phone number. Foreign key to PhoneNumberType.PhoneNumberTypeID.
    ModifiedDatedatetime8
    False
    (getdate())Date and time the record was last updated.
    KeyNameKey ColumnsUniqueDescription
    Cluster Primary Key PK_PersonPhone_BusinessEntityID_PhoneNumber_PhoneNumberTypeID: BusinessEntityID\PhoneNumber\PhoneNumberTypeIDPK_PersonPhone_BusinessEntityID_PhoneNumber_PhoneNumberTypeIDBusinessEntityID, PhoneNumber, PhoneNumberTypeID
    True
    Primary key (clustered) constraint
    IX_PersonPhone_PhoneNumberPhoneNumberNonclustered index.
    NameColumnsDescription
    FK_PersonPhone_Person_BusinessEntityIDBusinessEntityID->[Person].[Person].[BusinessEntityID]Foreign key constraint referencing Person.BusinessEntityID.
    FK_PersonPhone_PhoneNumberType_PhoneNumberTypeIDPhoneNumberTypeID->[Person].[PhoneNumberType].[PhoneNumberTypeID]Foreign key constraint referencing PhoneNumberType.PhoneNumberTypeID.
    CREATE TABLE [Person].[PersonPhone]
    (
    [BusinessEntityID] [int] NOT NULL,
    [PhoneNumber] [dbo].[Phone] NOT NULL,
    [PhoneNumberTypeID] [int] NOT NULL,
    [ModifiedDate] [datetime] NOT NULL CONSTRAINT [DF_PersonPhone_ModifiedDate] DEFAULT (getdate())
    ) ON [PRIMARY]
    GO
    ALTER TABLE [Person].[PersonPhone] ADD CONSTRAINT [PK_PersonPhone_BusinessEntityID_PhoneNumber_PhoneNumberTypeID] PRIMARY KEY CLUSTERED  ([BusinessEntityID], [PhoneNumber], [PhoneNumberTypeID]) ON [PRIMARY]
    GO
    CREATE NONCLUSTERED INDEX [IX_PersonPhone_PhoneNumber] ON [Person].[PersonPhone] ([PhoneNumber]) ON [PRIMARY]
    GO
    ALTER TABLE [Person].[PersonPhone] ADD CONSTRAINT [FK_PersonPhone_Person_BusinessEntityID] FOREIGN KEY ([BusinessEntityID]) REFERENCES [Person].[Person] ([BusinessEntityID])
    GO
    ALTER TABLE [Person].[PersonPhone] ADD CONSTRAINT [FK_PersonPhone_PhoneNumberType_PhoneNumberTypeID] FOREIGN KEY ([PhoneNumberTypeID]) REFERENCES [Person].[PhoneNumberType] ([PhoneNumberTypeID])
    GO
    EXEC sp_addextendedproperty N'MS_Description', N'Telephone number and type of a person.', 'SCHEMA', N'Person', 'TABLE', N'PersonPhone', NULL, NULL
    GO
    EXEC sp_addextendedproperty N'MS_Description', N'Business entity identification number. Foreign key to Person.BusinessEntityID.', 'SCHEMA', N'Person', 'TABLE', N'PersonPhone', 'COLUMN', N'BusinessEntityID'
    GO
    EXEC sp_addextendedproperty N'MS_Description', N'Date and time the record was last updated.', 'SCHEMA', N'Person', 'TABLE', N'PersonPhone', 'COLUMN', N'ModifiedDate'
    GO
    EXEC sp_addextendedproperty N'MS_Description', N'Telephone number identification number.', 'SCHEMA', N'Person', 'TABLE', N'PersonPhone', 'COLUMN', N'PhoneNumber'
    GO
    EXEC sp_addextendedproperty N'MS_Description', N'Kind of phone number. Foreign key to PhoneNumberType.PhoneNumberTypeID.', 'SCHEMA', N'Person', 'TABLE', N'PersonPhone', 'COLUMN', N'PhoneNumberTypeID'
    GO
    EXEC sp_addextendedproperty N'MS_Description', N'Default constraint value of GETDATE()', 'SCHEMA', N'Person', 'TABLE', N'PersonPhone', 'CONSTRAINT', N'DF_PersonPhone_ModifiedDate'
    GO
    EXEC sp_addextendedproperty N'MS_Description', N'Foreign key constraint referencing Person.BusinessEntityID.', 'SCHEMA', N'Person', 'TABLE', N'PersonPhone', 'CONSTRAINT', N'FK_PersonPhone_Person_BusinessEntityID'
    GO
    EXEC sp_addextendedproperty N'MS_Description', N'Foreign key constraint referencing PhoneNumberType.PhoneNumberTypeID.', 'SCHEMA', N'Person', 'TABLE', N'PersonPhone', 'CONSTRAINT', N'FK_PersonPhone_PhoneNumberType_PhoneNumberTypeID'
    GO
    EXEC sp_addextendedproperty N'MS_Description', N'Primary key (clustered) constraint', 'SCHEMA', N'Person', 'TABLE', N'PersonPhone', 'CONSTRAINT', N'PK_PersonPhone_BusinessEntityID_PhoneNumber_PhoneNumberTypeID'
    GO
    EXEC sp_addextendedproperty N'MS_Description', N'Nonclustered index.', 'SCHEMA', N'Person', 'TABLE', N'PersonPhone', 'INDEX', N'IX_PersonPhone_PhoneNumber'
    GO
    EXEC sp_addextendedproperty N'MS_Description', N'Clustered index created by a primary key constraint.', 'SCHEMA', N'Person', 'TABLE', N'PersonPhone', 'INDEX', N'PK_PersonPhone_BusinessEntityID_PhoneNumber_PhoneNumberTypeID'
    GO