Tables SQL 2005 Adventure Works OLTP

Purchasing.VendorContact

Object type: Table

Cross-reference table mapping vendors and their employees.

Columns 

Name  Data type  Nullable  Description 
VendorID  int  No Primary key. 
ContactID  int  No Contact (Vendor employee) identification number. Foreign key to Contact.ContactID. 
ContactTypeID  int  No Contact type such as sales manager, or sales agent. 
ModifiedDate  datetime  No Default value: GETDATE()
Date and time the record was last updated. 

Constraints 

Name  Type  Columns  Description 
DF_VendorContact_ModifiedDate  DEFAULT  ModifiedDate  Value: GETDATE()
Default constraint value of GETDATE() 
PK_VendorContact_VendorID_ContactID  PRIMARY KEY  VendorID
ContactID 
Clustered index created by a primary key constraint. 
FK_VendorContact_Contact_ContactID  FOREIGN KEY  ContactID  Reference table: Person.Contact
Foreign key constraint referencing Contact.ContactID. 
FK_VendorContact_ContactType_ContactTypeID  FOREIGN KEY  ContactTypeID  Reference table: Person.ContactType
Foreign key constraint referencing ContactType.ContactTypeID. 
FK_VendorContact_Vendor_VendorID  FOREIGN KEY  VendorID  Reference table: Purchasing.Vendor
Foreign key constraint referencing Vendor.VendorID. 

Indices 

Name  Description 
IX_VendorContact_ContactID  Nonclustered index. 
IX_VendorContact_ContactTypeID  Nonclustered index. 

Triggers 

Name  Description 
Purchasing.uVendorContact  AFTER UPDATE trigger setting the ModifiedDate column in the VendorContact table to the current date. 

Accessed by 

Name  Description 
dbo.ufnGetContactInformation  Table value function returning the first name, last name, job title and contact type for a given contact. 
Purchasing.vVendor  Vendor (company) names and addresses and the names of vendor employees to contact. 

Modified by 

Name  Description 
Purchasing.uVendorContact  AFTER UPDATE trigger setting the ModifiedDate column in the VendorContact table to the current date. 

Applies to

Tables | User
The AdventureWorks database sample was developed by Microsoft Corporation, copyright 2005. SQL Server is a trademark of Microsoft Corporation

Document was prepared on: Thursday, April 05, 2007
Help compiled by DBDocumentor, a Pikauba Software product. All rights reserved.