Audit table tracking all DDL changes made to the AdventureWorks database. Data is captured by the database trigger ddlDatabaseTriggerLog.
DatabaseLogIDINTEGER · PKPostTimeTEXTDatabaseUserTEXTEventTEXTSchemaTEXT · nullableObjectTEXT · nullableTSQLTEXTXmlEventTEXT
Audit table tracking errors in the the AdventureWorks database that are caught by the CATCH block of a TRY...CATCH construct. Data is inserted by stored procedure dbo.uspLogError when it is executed from inside the CATCH block of a TRY...CATCH construct.
ErrorLogIDINTEGER · PKErrorTimeTEXTUserNameTEXTErrorNumberINTEGERErrorSeverityINTEGER · nullableErrorStateINTEGER · nullableErrorProcedureTEXT · nullableErrorLineINTEGER · nullableErrorMessageTEXT
Street address information for customers, employees, and vendors.
AddressIDINTEGER · PKAddressLine1TEXTAddressLine2TEXT · nullableCityTEXTStateProvinceIDINTEGERPostalCodeTEXTSpatialLocationBLOB · nullablerowguidTEXTModifiedDateTEXT
References Person.StateProvince.StateProvinceID
Types of addresses stored in the Address table.
AddressTypeIDINTEGER · PKNameTEXTrowguidTEXTModifiedDateTEXT
Current version number of the AdventureWorks 2025 sample database.
SystemInformationIDINTEGER · PKDatabase VersionTEXTVersionDateTEXTModifiedDateTEXT
table
Production.BillOfMaterials
9 columns · 2,679 rows Items required to make bicycles and bicycle subassemblies. It identifies the heirarchical relationship between a parent product and its components.
BillOfMaterialsIDINTEGER · PKProductAssemblyIDINTEGER · nullableComponentIDINTEGERStartDateTEXTEndDateTEXT · nullableUnitMeasureCodeTEXTBOMLevelINTEGERPerAssemblyQtyNUMERICModifiedDateTEXT
References Production.UnitMeasure.UnitMeasureCode, Production.Product.ProductID, Production.Product.ProductID
table
Person.BusinessEntity
3 columns · 20,777 rows Source of the ID that connects vendors, customers, and employees with address and contact information.
BusinessEntityIDINTEGER · PKrowguidTEXTModifiedDateTEXT
table
Person.BusinessEntityAddress
5 columns · 19,614 rows Cross-reference table mapping customers, vendors, and employees to their addresses.
BusinessEntityIDINTEGER · PKAddressIDINTEGER · PKAddressTypeIDINTEGER · PKrowguidTEXTModifiedDateTEXT
References Person.BusinessEntity.BusinessEntityID, Person.AddressType.AddressTypeID, Person.Address.AddressID
table
Person.BusinessEntityContact
5 columns · 909 rows Cross-reference table mapping stores, vendors, and employees to people
BusinessEntityIDINTEGER · PKPersonIDINTEGER · PKContactTypeIDINTEGER · PKrowguidTEXTModifiedDateTEXT
References Person.BusinessEntity.BusinessEntityID, Person.ContactType.ContactTypeID, Person.Person.BusinessEntityID
Lookup table containing the types of business entity contacts.
ContactTypeIDINTEGER · PKNameTEXTModifiedDateTEXT
table
Sales.CountryRegionCurrency
3 columns · 109 rows Cross-reference table mapping ISO currency codes to a country or region.
CountryRegionCodeTEXT · PKCurrencyCodeTEXT · PKModifiedDateTEXT
References Sales.Currency.CurrencyCode, Person.CountryRegion.CountryRegionCode
table
Person.CountryRegion
3 columns · 238 rows Lookup table containing the ISO standard codes for countries and regions.
CountryRegionCodeTEXT · PKNameTEXTModifiedDateTEXT
Customer credit card information.
CreditCardIDINTEGER · PKCardTypeTEXTCardNumberTEXTExpMonthINTEGERExpYearINTEGERModifiedDateTEXT
Lookup table containing the languages in which some AdventureWorks data is stored.
CultureIDTEXT · PKNameTEXTModifiedDateTEXT
Lookup table containing standard ISO currencies.
CurrencyCodeTEXT · PKNameTEXTModifiedDateTEXT
Currency exchange rates.
CurrencyRateIDINTEGER · PKCurrencyRateDateTEXTFromCurrencyCodeTEXTToCurrencyCodeTEXTAverageRateNUMERICEndOfDayRateNUMERICModifiedDateTEXT
References Sales.Currency.CurrencyCode, Sales.Currency.CurrencyCode
Current customer information. Also see the Person and Store tables.
CustomerIDINTEGER · PKPersonIDINTEGER · nullableStoreIDINTEGER · nullableTerritoryIDINTEGER · nullableAccountNumberTEXT · nullablerowguidTEXTModifiedDateTEXT
References Sales.SalesTerritory.TerritoryID, Sales.Store.BusinessEntityID, Person.Person.BusinessEntityID
table
HumanResources.Department
4 columns · 16 rows Lookup table containing the departments within the Adventure Works Cycles company.
DepartmentIDINTEGER · PKNameTEXTGroupNameTEXTModifiedDateTEXT
Product maintenance documents.
DocumentNodeBLOB · PKDocumentLevelINTEGER · nullableTitleTEXTOwnerINTEGERFolderFlagINTEGERFileNameTEXTFileExtensionTEXTRevisionTEXTChangeNumberINTEGERStatusINTEGERDocumentSummaryTEXT · nullableDocumentBLOB · nullablerowguidTEXTModifiedDateTEXT
References HumanResources.Employee.BusinessEntityID
Where to send a person email.
BusinessEntityIDINTEGER · PKEmailAddressIDINTEGER · PKEmailAddressTEXT · nullablerowguidTEXTModifiedDateTEXT
References Person.Person.BusinessEntityID
table
HumanResources.Employee
16 columns · 290 rows Employee information such as salary, department, and title.
BusinessEntityIDINTEGER · PKNationalIDNumberTEXTLoginIDTEXTOrganizationNodeBLOB · nullableOrganizationLevelINTEGER · nullableJobTitleTEXTBirthDateTEXTMaritalStatusTEXTGenderTEXTHireDateTEXTSalariedFlagINTEGERVacationHoursINTEGERSickLeaveHoursINTEGERCurrentFlagINTEGERrowguidTEXTModifiedDateTEXT
References Person.Person.BusinessEntityID
table
HumanResources.EmployeeDepartmentHistory
6 columns · 296 rows Employee department transfers.
BusinessEntityIDINTEGER · PKDepartmentIDINTEGER · PKShiftIDINTEGER · PKStartDateTEXT · PKEndDateTEXT · nullableModifiedDateTEXT
References HumanResources.Shift.ShiftID, HumanResources.Employee.BusinessEntityID, HumanResources.Department.DepartmentID
table
HumanResources.EmployeePayHistory
5 columns · 316 rows Employee pay history.
BusinessEntityIDINTEGER · PKRateChangeDateTEXT · PKRateNUMERICPayFrequencyINTEGERModifiedDateTEXT
References HumanResources.Employee.BusinessEntityID
table
Production.Illustration
3 columns · 5 rows Bicycle assembly diagrams.
IllustrationIDINTEGER · PKDiagramTEXT · nullableModifiedDateTEXT
table
HumanResources.JobCandidate
4 columns · 13 rows Résumés submitted to Human Resources by job applicants.
JobCandidateIDINTEGER · PKBusinessEntityIDINTEGER · nullableResumeTEXT · nullableModifiedDateTEXT
References HumanResources.Employee.BusinessEntityID
Product inventory and manufacturing locations.
LocationIDINTEGER · PKNameTEXTCostRateNUMERICAvailabilityNUMERICModifiedDateTEXT
One way hashed authentication information
BusinessEntityIDINTEGER · PKPasswordHashTEXTPasswordSaltTEXTrowguidTEXTModifiedDateTEXT
References Person.Person.BusinessEntityID
Human beings involved with AdventureWorks: employees, customer contacts, and vendor contacts.
BusinessEntityIDINTEGER · PKPersonTypeTEXTNameStyleINTEGERTitleTEXT · nullableFirstNameTEXTMiddleNameTEXT · nullableLastNameTEXTSuffixTEXT · nullableEmailPromotionINTEGERAdditionalContactInfoTEXT · nullableDemographicsTEXT · nullablerowguidTEXTModifiedDateTEXT
References Person.BusinessEntity.BusinessEntityID
table
Sales.PersonCreditCard
3 columns · 19,118 rows Cross-reference table mapping people to their credit card information in the CreditCard table.
BusinessEntityIDINTEGER · PKCreditCardIDINTEGER · PKModifiedDateTEXT
References Sales.CreditCard.CreditCardID, Person.Person.BusinessEntityID
Telephone number and type of a person.
BusinessEntityIDINTEGER · PKPhoneNumberTEXT · PKPhoneNumberTypeIDINTEGER · PKModifiedDateTEXT
References Person.PhoneNumberType.PhoneNumberTypeID, Person.Person.BusinessEntityID
table
Person.PhoneNumberType
3 columns · 3 rows Type of phone number of a person.
PhoneNumberTypeIDINTEGER · PKNameTEXTModifiedDateTEXT
Products sold or used in the manfacturing of sold products.
ProductIDINTEGER · PKNameTEXTProductNumberTEXTMakeFlagINTEGERFinishedGoodsFlagINTEGERColorTEXT · nullableSafetyStockLevelINTEGERReorderPointINTEGERStandardCostNUMERICListPriceNUMERICSizeTEXT · nullableSizeUnitMeasureCodeTEXT · nullableWeightUnitMeasureCodeTEXT · nullableWeightNUMERIC · nullableDaysToManufactureINTEGERProductLineTEXT · nullableClassTEXT · nullableStyleTEXT · nullableProductSubcategoryIDINTEGER · nullableProductModelIDINTEGER · nullableSellStartDateTEXTSellEndDateTEXT · nullableDiscontinuedDateTEXT · nullablerowguidTEXTModifiedDateTEXT
References Production.ProductSubcategory.ProductSubcategoryID, Production.ProductModel.ProductModelID, Production.UnitMeasure.UnitMeasureCode, Production.UnitMeasure.UnitMeasureCode
table
Production.ProductCategory
4 columns · 4 rows High-level product categorization.
ProductCategoryIDINTEGER · PKNameTEXTrowguidTEXTModifiedDateTEXT
table
Production.ProductCostHistory
5 columns · 395 rows Changes in the cost of a product over time.
ProductIDINTEGER · PKStartDateTEXT · PKEndDateTEXT · nullableStandardCostNUMERICModifiedDateTEXT
References Production.Product.ProductID
table
Production.ProductDescription
4 columns · 762 rows Product descriptions in several languages.
ProductDescriptionIDINTEGER · PKDescriptionTEXTrowguidTEXTModifiedDateTEXT
table
Production.ProductDocument
3 columns · 32 rows Cross-reference table mapping products to related product documents.
ProductIDINTEGER · PKDocumentNodeBLOB · PKModifiedDateTEXT
References Production.Document.DocumentNode, Production.Product.ProductID
table
Production.ProductInventory
7 columns · 1,069 rows Product inventory information.
ProductIDINTEGER · PKLocationIDINTEGER · PKShelfTEXTBinINTEGERQuantityINTEGERrowguidTEXTModifiedDateTEXT
References Production.Product.ProductID, Production.Location.LocationID
table
Production.ProductListPriceHistory
5 columns · 395 rows Changes in the list price of a product over time.
ProductIDINTEGER · PKStartDateTEXT · PKEndDateTEXT · nullableListPriceNUMERICModifiedDateTEXT
References Production.Product.ProductID
table
Production.ProductModel
6 columns · 128 rows Product model classification.
ProductModelIDINTEGER · PKNameTEXTCatalogDescriptionTEXT · nullableInstructionsTEXT · nullablerowguidTEXTModifiedDateTEXT
table
Production.ProductModelIllustration
3 columns · 7 rows Cross-reference table mapping product models and illustrations.
ProductModelIDINTEGER · PKIllustrationIDINTEGER · PKModifiedDateTEXT
References Production.Illustration.IllustrationID, Production.ProductModel.ProductModelID
table
Production.ProductModelProductDescriptionCulture
4 columns · 762 rows Cross-reference table mapping product descriptions and the language the description is written in.
ProductModelIDINTEGER · PKProductDescriptionIDINTEGER · PKCultureIDTEXT · PKModifiedDateTEXT
References Production.ProductModel.ProductModelID, Production.Culture.CultureID, Production.ProductDescription.ProductDescriptionID
table
Production.ProductPhoto
6 columns · 101 rows Product images.
ProductPhotoIDINTEGER · PKThumbNailPhotoBLOB · nullableThumbnailPhotoFileNameTEXT · nullableLargePhotoBLOB · nullableLargePhotoFileNameTEXT · nullableModifiedDateTEXT
table
Production.ProductProductPhoto
4 columns · 504 rows Cross-reference table mapping products and product photos.
ProductIDINTEGER · PKProductPhotoIDINTEGER · PKPrimaryINTEGERModifiedDateTEXT
References Production.ProductPhoto.ProductPhotoID, Production.Product.ProductID
table
Production.ProductReview
8 columns · 4 rows Customer reviews of products they have purchased.
ProductReviewIDINTEGER · PKProductIDINTEGERReviewerNameTEXTReviewDateTEXTEmailAddressTEXTRatingINTEGERCommentsTEXT · nullableModifiedDateTEXT
References Production.Product.ProductID
table
Production.ProductSubcategory
5 columns · 37 rows Product subcategories. See ProductCategory table.
ProductSubcategoryIDINTEGER · PKProductCategoryIDINTEGERNameTEXTrowguidTEXTModifiedDateTEXT
References Production.ProductCategory.ProductCategoryID
table
Purchasing.ProductVendor
11 columns · 460 rows Cross-reference table mapping vendors with the products they supply.
ProductIDINTEGER · PKBusinessEntityIDINTEGER · PKAverageLeadTimeINTEGERStandardPriceNUMERICLastReceiptCostNUMERIC · nullableLastReceiptDateTEXT · nullableMinOrderQtyINTEGERMaxOrderQtyINTEGEROnOrderQtyINTEGER · nullableUnitMeasureCodeTEXTModifiedDateTEXT
References Purchasing.Vendor.BusinessEntityID, Production.UnitMeasure.UnitMeasureCode, Production.Product.ProductID
table
Purchasing.PurchaseOrderDetail
11 columns · 8,845 rows Individual products associated with a specific purchase order. See PurchaseOrderHeader.
PurchaseOrderIDINTEGER · PKPurchaseOrderDetailIDINTEGER · PKDueDateTEXTOrderQtyINTEGERProductIDINTEGERUnitPriceNUMERICLineTotalNUMERIC · nullableReceivedQtyNUMERICRejectedQtyNUMERICStockedQtyNUMERIC · nullableModifiedDateTEXT
References Purchasing.PurchaseOrderHeader.PurchaseOrderID, Production.Product.ProductID
table
Purchasing.PurchaseOrderHeader
13 columns · 4,012 rows General purchase order information. See PurchaseOrderDetail.
PurchaseOrderIDINTEGER · PKRevisionNumberINTEGERStatusINTEGEREmployeeIDINTEGERVendorIDINTEGERShipMethodIDINTEGEROrderDateTEXTShipDateTEXT · nullableSubTotalNUMERICTaxAmtNUMERICFreightNUMERICTotalDueNUMERICModifiedDateTEXT
References Purchasing.ShipMethod.ShipMethodID, Purchasing.Vendor.BusinessEntityID, HumanResources.Employee.BusinessEntityID
table
Sales.SalesOrderDetail
11 columns · 121,317 rows Individual products associated with a specific sales order. See SalesOrderHeader.
SalesOrderIDINTEGER · PKSalesOrderDetailIDINTEGER · PKCarrierTrackingNumberTEXT · nullableOrderQtyINTEGERProductIDINTEGERSpecialOfferIDINTEGERUnitPriceNUMERICUnitPriceDiscountNUMERICLineTotalNUMERIC · nullablerowguidTEXTModifiedDateTEXT
References Sales.SpecialOfferProduct.SpecialOfferID, Sales.SpecialOfferProduct.ProductID, Sales.SalesOrderHeader.SalesOrderID
table
Sales.SalesOrderHeader
26 columns · 31,465 rows General sales order information.
SalesOrderIDINTEGER · PKRevisionNumberINTEGEROrderDateTEXTDueDateTEXTShipDateTEXT · nullableStatusINTEGEROnlineOrderFlagINTEGERSalesOrderNumberTEXT · nullablePurchaseOrderNumberTEXT · nullableAccountNumberTEXT · nullableCustomerIDINTEGERSalesPersonIDINTEGER · nullableTerritoryIDINTEGER · nullableBillToAddressIDINTEGERShipToAddressIDINTEGERShipMethodIDINTEGERCreditCardIDINTEGER · nullableCreditCardApprovalCodeTEXT · nullableCurrencyRateIDINTEGER · nullableSubTotalNUMERICTaxAmtNUMERICFreightNUMERICTotalDueNUMERIC · nullableCommentTEXT · nullablerowguidTEXTModifiedDateTEXT
References Sales.SalesTerritory.TerritoryID, Purchasing.ShipMethod.ShipMethodID, Sales.SalesPerson.BusinessEntityID, Sales.Customer.CustomerID, Sales.CurrencyRate.CurrencyRateID, Sales.CreditCard.CreditCardID, Person.Address.AddressID, Person.Address.AddressID
table
Sales.SalesOrderHeaderSalesReason
3 columns · 27,647 rows Cross-reference table mapping sales orders to sales reason codes.
SalesOrderIDINTEGER · PKSalesReasonIDINTEGER · PKModifiedDateTEXT
References Sales.SalesOrderHeader.SalesOrderID, Sales.SalesReason.SalesReasonID
Sales representative current information.
BusinessEntityIDINTEGER · PKTerritoryIDINTEGER · nullableSalesQuotaNUMERIC · nullableBonusNUMERICCommissionPctNUMERICSalesYTDNUMERICSalesLastYearNUMERICrowguidTEXTModifiedDateTEXT
References Sales.SalesTerritory.TerritoryID, HumanResources.Employee.BusinessEntityID
table
Sales.SalesPersonQuotaHistory
5 columns · 163 rows Sales performance tracking.
BusinessEntityIDINTEGER · PKQuotaDateTEXT · PKSalesQuotaNUMERICrowguidTEXTModifiedDateTEXT
References Sales.SalesPerson.BusinessEntityID
Lookup table of customer purchase reasons.
SalesReasonIDINTEGER · PKNameTEXTReasonTypeTEXTModifiedDateTEXT
Tax rate lookup table.
SalesTaxRateIDINTEGER · PKStateProvinceIDINTEGERTaxTypeINTEGERTaxRateNUMERICNameTEXTrowguidTEXTModifiedDateTEXT
References Person.StateProvince.StateProvinceID
table
Sales.SalesTerritory
10 columns · 10 rows Sales territory lookup table.
TerritoryIDINTEGER · PKNameTEXTCountryRegionCodeTEXTGroupTEXTSalesYTDNUMERICSalesLastYearNUMERICCostYTDNUMERICCostLastYearNUMERICrowguidTEXTModifiedDateTEXT
References Person.CountryRegion.CountryRegionCode
table
Sales.SalesTerritoryHistory
6 columns · 17 rows Sales representative transfers to other sales territories.
BusinessEntityIDINTEGER · PKTerritoryIDINTEGER · PKStartDateTEXT · PKEndDateTEXT · nullablerowguidTEXTModifiedDateTEXT
References Sales.SalesTerritory.TerritoryID, Sales.SalesPerson.BusinessEntityID
table
Production.ScrapReason
3 columns · 16 rows Manufacturing failure reasons lookup table.
ScrapReasonIDINTEGER · PKNameTEXTModifiedDateTEXT
table
HumanResources.Shift
5 columns · 3 rows Work shift lookup table.
ShiftIDINTEGER · PKNameTEXTStartTimeTEXTEndTimeTEXTModifiedDateTEXT
table
Purchasing.ShipMethod
6 columns · 5 rows Shipping company lookup table.
ShipMethodIDINTEGER · PKNameTEXTShipBaseNUMERICShipRateNUMERICrowguidTEXTModifiedDateTEXT
table
Sales.ShoppingCartItem
6 columns · 3 rows Contains online customer orders until the order is submitted or cancelled.
ShoppingCartItemIDINTEGER · PKShoppingCartIDTEXTQuantityINTEGERProductIDINTEGERDateCreatedTEXTModifiedDateTEXT
References Production.Product.ProductID
Sale discounts lookup table.
SpecialOfferIDINTEGER · PKDescriptionTEXTDiscountPctNUMERICTypeTEXTCategoryTEXTStartDateTEXTEndDateTEXTMinQtyINTEGERMaxQtyINTEGER · nullablerowguidTEXTModifiedDateTEXT
table
Sales.SpecialOfferProduct
4 columns · 538 rows Cross-reference table mapping products to special offer discounts.
SpecialOfferIDINTEGER · PKProductIDINTEGER · PKrowguidTEXTModifiedDateTEXT
References Sales.SpecialOffer.SpecialOfferID, Production.Product.ProductID
table
Person.StateProvince
8 columns · 181 rows State and province lookup table.
StateProvinceIDINTEGER · PKStateProvinceCodeTEXTCountryRegionCodeTEXTIsOnlyStateProvinceFlagINTEGERNameTEXTTerritoryIDINTEGERrowguidTEXTModifiedDateTEXT
References Sales.SalesTerritory.TerritoryID, Person.CountryRegion.CountryRegionCode
Customers (resellers) of Adventure Works products.
BusinessEntityIDINTEGER · PKNameTEXTSalesPersonIDINTEGER · nullableDemographicsTEXT · nullablerowguidTEXTModifiedDateTEXT
References Sales.SalesPerson.BusinessEntityID, Person.BusinessEntity.BusinessEntityID
table
Production.TransactionHistory
9 columns · 113,443 rows Record of each purchase order, sales order, or work order transaction year to date.
TransactionIDINTEGER · PKProductIDINTEGERReferenceOrderIDINTEGERReferenceOrderLineIDINTEGERTransactionDateTEXTTransactionTypeTEXTQuantityINTEGERActualCostNUMERICModifiedDateTEXT
References Production.Product.ProductID
table
Production.TransactionHistoryArchive
9 columns · 89,253 rows Transactions for previous years.
TransactionIDINTEGER · PKProductIDINTEGERReferenceOrderIDINTEGERReferenceOrderLineIDINTEGERTransactionDateTEXTTransactionTypeTEXTQuantityINTEGERActualCostNUMERICModifiedDateTEXT
table
Production.UnitMeasure
3 columns · 38 rows Unit of measure lookup table.
UnitMeasureCodeTEXT · PKNameTEXTModifiedDateTEXT
Companies from whom Adventure Works Cycles purchases parts or other goods.
BusinessEntityIDINTEGER · PKAccountNumberTEXTNameTEXTCreditRatingINTEGERPreferredVendorStatusINTEGERActiveFlagINTEGERPurchasingWebServiceURLTEXT · nullableModifiedDateTEXT
References Person.BusinessEntity.BusinessEntityID
table
Production.WorkOrder
10 columns · 72,591 rows Manufacturing orders to produce specified products.
WorkOrderIDINTEGER · PKProductIDINTEGEROrderQtyINTEGERStockedQtyNUMERIC · nullableScrappedQtyINTEGERStartDateTEXTEndDateTEXT · nullableDueDateTEXTScrapReasonIDINTEGER · nullableModifiedDateTEXT
References Production.ScrapReason.ScrapReasonID, Production.Product.ProductID
table
Production.WorkOrderRouting
12 columns · 67,131 rows Manufacturing routing operations and scheduling information for each work order.
WorkOrderIDINTEGER · PKProductIDINTEGER · PKOperationSequenceINTEGER · PKLocationIDINTEGERScheduledStartDateTEXTScheduledEndDateTEXTActualStartDateTEXT · nullableActualEndDateTEXT · nullableActualResourceHrsNUMERIC · nullablePlannedCostNUMERICActualCostNUMERIC · nullableModifiedDateTEXT
References Production.WorkOrder.WorkOrderID, Production.Location.LocationID