Purchasing.Vendor
| Documentation | AdventureWorks |
| Schema | Purchasing |
| Name | Vendor |
| Module | Purchasing |
Companies from whom Adventure Works Cycles purchases parts or other goods.
Columns
| Key | Name | Data type | Null | Attributes | References | Description | ||
|---|---|---|---|---|---|---|---|---|
| 1 | BusinessEntityID | int | Person.BusinessEntity | Primary key for Vendor records. Foreign key to BusinessEntity.BusinessEntityID | ||||
| Primary key for Vendor records. Foreign key to BusinessEntity.BusinessEntityID References: Person.BusinessEntity |
||||||||
| 2 | AccountNumber | nvarchar(15) | Vendor account (identification) number. | |||||
| Vendor account (identification) number. |
||||||||
| 3 | Name | nvarchar(50) | Company name. | |||||
| Company name. |
||||||||
| 4 | CreditRating | tinyint | 1 = Superior, 2 = Excellent, 3 = Above average, 4 = Average, 5 = Below average | |||||
| 1 = Superior, 2 = Excellent, 3 = Above average, 4 = Average, 5 = Below average |
||||||||
| 5 | PreferredVendorStatus | bit | Default: 1 | 0 = Do not use if another vendor is available. 1 = Preferred over other vendors supplying the same product. | ||||
| 0 = Do not use if another vendor is available. 1 = Preferred over other vendors supplying the same product. Default: 1 |
||||||||
| 6 | ActiveFlag | bit | Default: 1 | 0 = Vendor no longer used. 1 = Vendor is actively used. | ||||
| 0 = Vendor no longer used. 1 = Vendor is actively used. Default: 1 |
||||||||
| 7 | PurchasingWebServiceURL | nvarchar(1024) | Vendor URL. | |||||
| Vendor URL. |
||||||||
| 8 | ModifiedDate | datetime | Default: getdate() | Date and time the record was last updated. | ||||
| Date and time the record was last updated. Default: getdate() |
||||||||
Relations
| Foreign table | Primary table | Join | Title / Name / Description | |
|---|---|---|---|---|
| Purchasing.Vendor | Person.BusinessEntity | Purchasing.Vendor.BusinessEntityID = Person.BusinessEntity.BusinessEntityID | FK_Vendor_BusinessEntity_BusinessEntityID Foreign key constraint referencing BusinessEntity.BusinessEntityID |
|
|
Purchasing.Vendor.BusinessEntityID = Person.BusinessEntity.BusinessEntityID Name: FK_Vendor_BusinessEntity_BusinessEntityIDForeign key constraint referencing BusinessEntity.BusinessEntityID |
||||
| Purchasing.ProductVendor | Purchasing.Vendor | Purchasing.ProductVendor.BusinessEntityID = Purchasing.Vendor.BusinessEntityID | FK_ProductVendor_Vendor_BusinessEntityID Foreign key constraint referencing Vendor.BusinessEntityID. |
|
|
Purchasing.ProductVendor.BusinessEntityID = Purchasing.Vendor.BusinessEntityID Name: FK_ProductVendor_Vendor_BusinessEntityIDForeign key constraint referencing Vendor.BusinessEntityID. |
||||
| Purchasing.PurchaseOrderHeader | Purchasing.Vendor | Purchasing.PurchaseOrderHeader.VendorID = Purchasing.Vendor.BusinessEntityID | FK_PurchaseOrderHeader_Vendor_VendorID Foreign key constraint referencing Vendor.VendorID. |
|
|
Purchasing.PurchaseOrderHeader.VendorID = Purchasing.Vendor.BusinessEntityID Name: FK_PurchaseOrderHeader_Vendor_VendorIDForeign key constraint referencing Vendor.VendorID. |
||||
Unique keys
| Key name | Columns | Description | |
|---|---|---|---|
| PK_Vendor_BusinessEntityID | BusinessEntityID | Primary key (clustered) constraint | |
| Primary key (clustered) constraint | |||
| AK_Vendor_AccountNumber | AccountNumber | Unique nonclustered index. | |
| Unique nonclustered index. | |||
Triggers
| Key name | When | Description | |
|---|---|---|---|
| dVendor | Instead Of Delete | INSTEAD OF DELETE trigger which keeps Vendors from being deleted. | |
| INSTEAD OF DELETE trigger which keeps Vendors from being deleted. | |||
Uses
| Name |
|---|
|
Purchasing.Vendor
|
|
Purchasing.dVendor
|
Used by
Exported: 2019-02-04 23:13, Last imported: 2018-03-07 11:56
