Properties

Owner: Purchasing 
Creation Date: 04/26/2006 
Located On: PRIMARY 
Data Size KB:
Index Size KB: 24 
Rows: 104 
Description: Cross-reference mapping vendors and addresses. 

Columns

Name Data Type Length NULL Default IsIdentity IsGUID Description
    VendorID  int          Primary key. Foreign key to Vendor.VendorID. 
    AddressID  int          Primary key. Foreign key to Address.AddressID. 
    AddressTypeID  int          Address type. Foreign key to AddressType.AddressTypeID. 
    ModifiedDate  datetime    (getdate())      Date and time the record was last updated. 
Total: 4 column(s)

Indexes

Index Primary Unique Description
  PK_VendorAddress_VendorID_AddressID      Primary key (clustered) constraint 
  IX_VendorAddress_AddressID      Nonclustered index. 
Total: 2 index(es)

Referenced Tables

Table Foreign Key Primary Key or Unique Constraint
  Person.Address  FK_VendorAddress_Address_AddressID  PK_Address_AddressID 
  Person.AddressType  FK_VendorAddress_AddressType_AddressTypeID  PK_AddressType_AddressTypeID 
  Purchasing.Vendor  FK_VendorAddress_Vendor_VendorID  PK_Vendor_VendorID 
Total: 3 table(s)

Objects that [Purchasing].[VendorAddress] depends on

Object Name Owner Object Type Dep Level
  AccountNumber  dbo  User Defined type 
  Flag  dbo  User Defined type 
  Name  dbo  User Defined type 
  AddressType  Person  Table 
  CountryRegion  Person  Table 
  SalesTerritory  Sales  Table 
  Vendor  Purchasing  Table 
  StateProvince  Person  Table 
  Address  Person  Table 
Total: 9 object(s)

Objects that depend on [Purchasing].[VendorAddress]

Object Name Owner Object Type Dep Level
  vVendor  Purchasing  View 
Total: 1 object(s)

SQL

CREATE TABLE [VendorAddress] (
    [VendorID] [int] NOT NULL ,
    [AddressID] [int] NOT NULL ,
    [AddressTypeID] [int] NOT NULL ,
    [ModifiedDate] [datetime] NOT NULL CONSTRAINT [DF_VendorAddress_ModifiedDate] DEFAULT (getdate()),
    CONSTRAINT [PK_VendorAddress_VendorID_AddressID] PRIMARY KEY  CLUSTERED
    (
        [VendorID],
        [AddressID]
    )  ON [PRIMARY] ,
    CONSTRAINT [FK_VendorAddress_Address_AddressID] FOREIGN KEY
    (
        [AddressID]
    ) REFERENCES [Address] (
        [AddressID]
    ),
    CONSTRAINT [FK_VendorAddress_AddressType_AddressTypeID] FOREIGN KEY
    (
        [AddressTypeID]
    ) REFERENCES [AddressType] (
        [AddressTypeID]
    ),
    CONSTRAINT [FK_VendorAddress_Vendor_VendorID] FOREIGN KEY
    (
        [VendorID]
    ) REFERENCES [Vendor] (
        [VendorID]
    )
) ON [PRIMARY]
GO


See Also

List of tables