Tables | SQL 2005 Adventure Works OLTP |
Street address information for customers, employees, and vendors.
Columns
Name Data type Nullable Description AddressID int No Column has identity seed value of 1 with a step value of 1.
Primary key for Address records.AddressLine1 nvarchar(60) No First street address line. AddressLine2 nvarchar(60) Yes Second street address line. City nvarchar(30) No Name of the city. StateProvinceID int No Unique identification number for the state or province. Foreign key to StateProvince table. PostalCode nvarchar(15) No Postal code for the street address. rowguid uniqueidentifier No Default value: NEWID()
ROWGUIDCOL number uniquely identifying the record. Used to support a merge replication sample.ModifiedDate datetime No Default value: GETDATE()
Date and time the record was last updated.
Constraints
Name Type Columns Description DF_Address_rowguid DEFAULT rowguid Value: NEWID()
Default constraint value of NEWID()DF_Address_ModifiedDate DEFAULT ModifiedDate Value: GETDATE()
Default constraint value of GETDATE()PK_Address_AddressID PRIMARY KEY AddressID Clustered index created by a primary key constraint. FK_Address_StateProvince_StateProvinceID FOREIGN KEY StateProvinceID Reference table: Person.StateProvince
Foreign key constraint referencing StateProvince.StateProvinceID.
Indices
Name Description AK_Address_rowguid Unique nonclustered index. Used to support replication samples. IX_Address_AddressLine1_AddressLine2_City_StateProvinceID_PostalCode Nonclustered index. IX_Address_StateProvinceID Nonclustered index.
Triggers
Name Description Person.uAddress AFTER UPDATE trigger setting the ModifiedDate column in the Address table to the current date.
Linked tables
Name Description HumanResources.EmployeeAddress Cross-reference table mapping employees to their address(es). Purchasing.VendorAddress Cross-reference mapping vendors and addresses. Sales.CustomerAddress Cross-reference table mapping customers to their address(es). Sales.SalesOrderHeader General sales order information.
Accessed by
Name Description HumanResources.vEmployee Employee names and addresses. Purchasing.vVendor Vendor (company) names and addresses and the names of vendor employees to contact. Sales Order Detail Detail of an individual Adventure Works order. This report can be accessed as a drillthrough report from the Employee Sales Summary and Territory Sales drilldown report. This report illustrates the use of lists, tables, parameters, and expressions. Sales.vIndividual Individual customers (names and addresses) that purchase Adventure Works Cycles products online. Sales.vSalesPerson Sales representiatives (names and addresses) and their sales-related information. Sales.vStoreWithDemographics Stores (names and addresses) that sell Adventure Works Cycles products to consumers.
Modified by
Name Description Person.uAddress AFTER UPDATE trigger setting the ModifiedDate column in the Address table to the current date.
Applies to
Tables | User