Difference between revisions of "Sales.SalesTerritory (table)"

From dbscript Online Help
Jump to: navigation, search
 
(6 intermediate revisions by the same user not shown)
Line 2: Line 2:
  
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
|-
+
|- valign="top"
 
| '''Table
 
| '''Table
 
| Sales.SalesTerritory
 
| Sales.SalesTerritory
Line 8: Line 8:
 
| '''Description
 
| '''Description
 
| Sales territory lookup table.
 
| Sales territory lookup table.
|-
 
 
|}
 
|}
  
 
+
=== Columns ===
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
|- style="background:silver"
 
|- style="background:silver"
Line 18: Line 17:
 
| '''Nullable
 
| '''Nullable
 
| '''Default
 
| '''Default
| '''Description / PK / Index
+
| '''Description
+
 
 
|- valign="top"
 
|- valign="top"
 
| TerritoryID
 
| TerritoryID
Line 25: Line 24:
 
| not null
 
| not null
 
|  
 
|  
| Primary key for SalesTerritory records.<br />PK_SalesTerritory_TerritoryID
+
| Primary key for SalesTerritory records.
 
|- valign="top"
 
|- valign="top"
 
| Name
 
| Name
Line 31: Line 30:
 
| not null
 
| not null
 
|  
 
|  
| Sales territory description<br />AK_SalesTerritory_Name
+
| Sales territory description
 
|- valign="top"
 
|- valign="top"
 
| CountryRegionCode
 
| CountryRegionCode
Line 37: Line 36:
 
| not null
 
| not null
 
|  
 
|  
| ISO standard country or region code. Foreign key to CountryRegion.CountryRegionCode. <br />
+
| ISO standard country or region code. Foreign key to CountryRegion.CountryRegionCode.  
 
|- valign="top"
 
|- valign="top"
 
| Group
 
| Group
Line 43: Line 42:
 
| not null
 
| not null
 
|  
 
|  
| Geographic area to which the sales territory belong.<br />
+
| Geographic area to which the sales territory belong.
 
|- valign="top"
 
|- valign="top"
 
| SalesYTD
 
| SalesYTD
Line 49: Line 48:
 
| not null
 
| not null
 
| ((0.00))
 
| ((0.00))
| Sales in the territory year to date.<br />
+
| Sales in the territory year to date.
 
|- valign="top"
 
|- valign="top"
 
| SalesLastYear
 
| SalesLastYear
Line 55: Line 54:
 
| not null
 
| not null
 
| ((0.00))
 
| ((0.00))
| Sales in the territory the previous year.<br />
+
| Sales in the territory the previous year.
 
|- valign="top"
 
|- valign="top"
 
| CostYTD
 
| CostYTD
Line 61: Line 60:
 
| not null
 
| not null
 
| ((0.00))
 
| ((0.00))
| Business costs in the territory year to date.<br />
+
| Business costs in the territory year to date.
 
|- valign="top"
 
|- valign="top"
 
| CostLastYear
 
| CostLastYear
Line 67: Line 66:
 
| not null
 
| not null
 
| ((0.00))
 
| ((0.00))
| Business costs in the territory the previous year.<br />
+
| Business costs in the territory the previous year.
 
|- valign="top"
 
|- valign="top"
 
| rowguid
 
| rowguid
Line 73: Line 72:
 
| not null
 
| not null
 
| (newid())
 
| (newid())
| ROWGUIDCOL number uniquely identifying the record. Used to support a merge replication sample.<br />AK_SalesTerritory_rowguid
+
| ROWGUIDCOL number uniquely identifying the record. Used to support a merge replication sample.
 
|- valign="top"
 
|- valign="top"
 
| ModifiedDate
 
| ModifiedDate
Line 79: Line 78:
 
| not null
 
| not null
 
| (getdate())
 
| (getdate())
| Date and time the record was last updated.<br />
+
| Date and time the record was last updated.
 +
|}
 +
 
 +
=== Primary Key ===
 +
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 +
|- style="background:silver"
 +
| '''Primary Key
 +
| '''Columns
 +
|- valign="top"
 +
| PK_SalesTerritory_TerritoryID
 +
| TerritoryID
 +
|}
 +
 
 +
=== Indexes ===
 +
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 +
|- style="background:silver"
 +
| '''Index
 +
| '''Type
 +
| '''Columns
 +
 
 +
|- valign="top"
 +
| AK_SalesTerritory_Name
 +
| Unique
 +
| Name
 +
|- valign="top"
 +
| AK_SalesTerritory_rowguid
 +
| Unique
 +
| rowguid
 
|}
 
|}
  
 +
=== Check Constraints ===
 +
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 +
|- style="background:silver"
 +
| '''Check Constraint
 +
| '''Expression
 +
| '''Description
  
 +
|- valign="top"
 +
| CK_SalesTerritory_CostLastYear
 +
| ([CostLastYear]>=(0.00))
 +
| Check constraint [CostLastYear] >= (0.00)
 +
|- valign="top"
 +
| CK_SalesTerritory_CostYTD
 +
| ([CostYTD]>=(0.00))
 +
| Check constraint [CostYTD] >= (0.00)
 +
|- valign="top"
 +
| CK_SalesTerritory_SalesLastYear
 +
| ([SalesLastYear]>=(0.00))
 +
| Check constraint [SalesLastYear] >= (0.00)
 +
|- valign="top"
 +
| CK_SalesTerritory_SalesYTD
 +
| ([SalesYTD]>=(0.00))
 +
| Check constraint [SalesYTD] >= (0.00)
 +
|}
  
 +
=== Detail Tables ===
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
|- style="background:silver"
 
|- style="background:silver"
Line 89: Line 139:
 
| '''Column
 
| '''Column
 
| '''Referencing Column
 
| '''Referencing Column
+
 
|-
+
|- valign="top"
 
| [[Sales.Customer_(table)|Sales.Customer]]
 
| [[Sales.Customer_(table)|Sales.Customer]]
 
| TerritoryID
 
| TerritoryID
 
| TerritoryID
 
| TerritoryID
|-
+
|- valign="top"
 
| [[Sales.SalesOrderHeader_(table)|Sales.SalesOrderHeader]]
 
| [[Sales.SalesOrderHeader_(table)|Sales.SalesOrderHeader]]
 
| TerritoryID
 
| TerritoryID
 
| TerritoryID
 
| TerritoryID
|-
+
|- valign="top"
 
| [[Sales.SalesPerson_(table)|Sales.SalesPerson]]
 
| [[Sales.SalesPerson_(table)|Sales.SalesPerson]]
 
| TerritoryID
 
| TerritoryID
 
| TerritoryID
 
| TerritoryID
|-
+
|- valign="top"
 
| [[Sales.SalesTerritoryHistory_(table)|Sales.SalesTerritoryHistory]]
 
| [[Sales.SalesTerritoryHistory_(table)|Sales.SalesTerritoryHistory]]
 
| TerritoryID
 
| TerritoryID
 
| TerritoryID
 
| TerritoryID
|-
+
|- valign="top"
 
| [[Person.StateProvince_(table)|Person.StateProvince]]
 
| [[Person.StateProvince_(table)|Person.StateProvince]]
 
| TerritoryID
 
| TerritoryID
Line 112: Line 162:
 
|}
 
|}
  
 
+
=== References ===
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
|- style="background:silver"
 
|- style="background:silver"
Line 119: Line 169:
 
| '''Referenced Object
 
| '''Referenced Object
  
|-
+
|- valign="top"
 
| Data Type
 
| Data Type
 
| Type
 
| Type
 
| [[dbo.Name_(type)|dbo.Name]]
 
| [[dbo.Name_(type)|dbo.Name]]
 +
 +
|- valign="top"
 +
| Schema
 +
| Schema
 +
| [[Sales_(schema)|Sales]]
  
 
|}
 
|}
  
 
+
=== Dependencies ===
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
|- style="background:silver"
 
|- style="background:silver"
Line 136: Line 191:
 
| '''Child Object
 
| '''Child Object
  
|-
+
|- valign="top"
 
| Select
 
| Select
 
| View
 
| View
Line 143: Line 198:
 
|  
 
|  
 
|  
 
|  
|-
+
|- valign="top"
 
| Select
 
| Select
 
| View
 
| View
Line 150: Line 205:
 
|  
 
|  
 
|  
 
|  
|-
+
|- valign="top"
 
| Update
 
| Update
 
| Table
 
| Table
Line 158: Line 213:
 
| uSalesOrderHeader
 
| uSalesOrderHeader
 
|}
 
|}
 +
 +
 
== wikivalues ==
 
== wikivalues ==
  
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
|-
+
|- valign="top"
 
| '''Table Values
 
| '''Table Values
 
| Sales.SalesTerritory
 
| Sales.SalesTerritory
|-
 
 
|}
 
|}
  
 +
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 +
|- style="background:silver"
  
{| border="1" cellpadding="5" cellspacing="0"  style="border-collapse:collapse"
 
|- style="background:silver"
 
 
| '''TerritoryID
 
| '''TerritoryID
 
| '''Name
 
| '''Name
 
| '''CountryRegionCode
 
| '''CountryRegionCode
 
| '''Group
 
| '''Group
|-  
+
|- valign="top"
| 1
 
| Northwest
 
| US
 
| North America
 
|-
 
| 2
 
| Northeast
 
| US
 
| North America
 
|-
 
| 3
 
| Central
 
| US
 
| North America
 
|-
 
| 4
 
| Southwest
 
| US
 
| North America
 
|-
 
| 5
 
| Southeast
 
| US
 
| North America
 
|-
 
| 6
 
| Canada
 
| CA
 
| North America
 
|-
 
| 7
 
| France
 
| FR
 
| Europe
 
|-
 
| 8
 
| Germany
 
| DE
 
| Europe
 
|-
 
| 9
 
| Australia
 
| AU
 
| Pacific
 
|-
 
| 10
 
| United Kingdom
 
| GB
 
| Europe
 
|}
 
  
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
+
| 1
|-
+
| Northwest
| '''Table Values
+
| US
| Sales.SalesReason
+
| North America
|-
+
|- valign="top"
|}
 
  
 +
| 2
 +
| Northeast
 +
| US
 +
| North America
 +
|- valign="top"
  
{| border="1" cellpadding="5" cellspacing="0"  style="border-collapse:collapse"
+
| 3
|- style="background:silver"
+
| Central
| '''SalesReasonID
+
| US
| '''Name
+
| North America
| '''ReasonType
+
|- valign="top"
|-
 
| 1
 
| Price
 
| Other
 
|-
 
| 2
 
| On Promotion
 
| Promotion
 
|-
 
| 3
 
| Magazine Advertisement
 
| Marketing
 
|-
 
| 4
 
| Television  Advertisement
 
| Marketing
 
|-  
 
| 5
 
| Manufacturer
 
| Other
 
|-
 
| 6
 
| Review
 
| Other
 
|-
 
| 7
 
| Demo Event
 
| Marketing
 
|-
 
| 8
 
| Sponsorship
 
| Marketing
 
|-
 
| 9
 
| Quality
 
| Other
 
|-
 
| 10
 
| Other
 
| Other
 
|}
 
  
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
+
| 4
|-
+
| Southwest
| '''Table Values
+
| US
| Purchasing.ShipMethod
+
| North America
|-
+
|- valign="top"
|}
 
  
 +
| 5
 +
| Southeast
 +
| US
 +
| North America
 +
|- valign="top"
  
{| border="1" cellpadding="5" cellspacing="0"  style="border-collapse:collapse"
+
| 6
|- style="background:silver"
+
| Canada
| '''ShipMethodID
+
| CA
| '''Name
+
| North America
| '''ShipBase
+
|- valign="top"
| '''ShipRate
 
|-  
 
| 1
 
| XRQ - TRUCK GROUND
 
| 3.95
 
| 0.99
 
|-
 
| 2
 
| ZY - EXPRESS
 
| 9.95
 
| 1.99
 
|-
 
| 3
 
| OVERSEAS - DELUXE
 
| 29.95
 
| 2.99
 
|-
 
| 4
 
| OVERNIGHT J-FAST
 
| 21.95
 
| 1.29
 
|-
 
| 5
 
| CARGO TRANSPORT 5
 
| 8.99
 
| 1.49
 
|}
 
  
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
+
| 7
|-
+
| France
| '''Table Values
+
| FR
| Production.UnitMeasure
+
| Europe
|-
+
|- valign="top"
|}
 
  
 +
| 8
 +
| Germany
 +
| DE
 +
| Europe
 +
|- valign="top"
  
{| border="1" cellpadding="5" cellspacing="0"  style="border-collapse:collapse"
+
| 9
|- style="background:silver"
+
| Australia
| '''UnitMeasureCode
+
| AU
| '''Name
+
| Pacific
|-
+
|- valign="top"
| BTL
 
| Bottle
 
|-
 
| BOX
 
| Boxes
 
|-
 
| CAN
 
| Canister
 
|-
 
| CAR
 
| Carton
 
|-
 
| CS
 
| Case
 
|-
 
| C 
 
| Celsius
 
|-
 
| CM
 
| Centimeter
 
|-
 
| CTN
 
| Container
 
|-
 
| CR
 
| Crate
 
|-
 
| CCM
 
| Cubic centimeter
 
|-
 
| CDM
 
| Cubic decimeter
 
|-
 
| FT3
 
| Cubic foot
 
|-
 
| M3
 
| Cubic meter
 
|-
 
| CBM
 
| Cubic meters
 
|-
 
| DM
 
| Decimeter
 
|-
 
| DZ
 
| Dozen
 
|-
 
| EA
 
| Each
 
|-
 
| GAL
 
| Gallon
 
|-
 
| G 
 
| Gram
 
|-
 
| IN
 
| Inch
 
|-
 
| KG
 
| Kilogram
 
|-
 
| KGV
 
| Kilogram/cubic meter
 
|-
 
| KM
 
| Kilometer
 
|-
 
| KT
 
| Kiloton
 
|-
 
| L 
 
| Liter
 
|-
 
| M 
 
| Meter
 
|-
 
| MG
 
| Milligram
 
|-
 
| ML
 
| Milliliter
 
|-
 
| MM
 
| Millimeter
 
|-
 
| OZ
 
| Ounces
 
|-
 
| PAK
 
| Pack
 
|-
 
| PAL
 
| Pallet
 
|-
 
| PCT
 
| Percentage
 
|-
 
| PC
 
| Piece
 
|-
 
| PT
 
| Pint, US liquid
 
|-
 
| CM2
 
| Square centimeter
 
|-
 
| M2
 
| Square meter
 
|-
 
| LB
 
| US pound
 
|}
 
 
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
|-
 
| '''Table Values
 
| Production.ScrapReason
 
|-
 
|}
 
 
 
 
 
{| border="1" cellpadding="5" cellspacing="0"  style="border-collapse:collapse"
 
|- style="background:silver"
 
| '''ScrapReasonID
 
| '''Name
 
|-
 
| 1
 
| Brake assembly not as ordered
 
|-
 
| 2
 
| Color incorrect
 
|-
 
| 4
 
| Drill pattern incorrect
 
|-
 
| 5
 
| Drill size too large
 
|-
 
| 6
 
| Drill size too small
 
|-
 
| 3
 
| Gouge in metal
 
|-
 
| 7
 
| Handling damage
 
|-
 
| 8
 
| Paint process failed
 
|-
 
| 9
 
| Primer process failed
 
|-
 
| 10
 
| Seat assembly not as ordered
 
|-
 
| 11
 
| Stress test failed
 
|-
 
| 12
 
| Thermoform temperature too high
 
|-
 
| 13
 
| Thermoform temperature too low
 
|-
 
| 14
 
| Trim length too long
 
|-
 
| 15
 
| Trim length too short
 
|-
 
| 16
 
| Wheel misaligned
 
|}
 
 
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
|-
 
| '''Table Values
 
| Production.Location
 
|-
 
|}
 
 
 
 
 
{| border="1" cellpadding="5" cellspacing="0"  style="border-collapse:collapse"
 
|- style="background:silver"
 
| '''LocationID
 
| '''Name
 
| '''CostRate
 
| '''Availability
 
|-
 
| 1
 
| Tool Crib
 
| 0.00
 
| 0.00
 
|-
 
| 2
 
| Sheet Metal Racks
 
| 0.00
 
| 0.00
 
|-
 
| 3
 
| Paint Shop
 
| 0.00
 
| 0.00
 
|-
 
| 4
 
| Paint Storage
 
| 0.00
 
| 0.00
 
|-
 
| 5
 
| Metal Storage
 
| 0.00
 
| 0.00
 
|-
 
| 6
 
| Miscellaneous Storage
 
| 0.00
 
| 0.00
 
|-
 
| 7
 
| Finished Goods Storage
 
| 0.00
 
| 0.00
 
|-
 
| 10
 
| Frame Forming
 
| 22.50
 
| 96.00
 
|-
 
| 20
 
| Frame Welding
 
| 25.00
 
| 108.00
 
|-
 
| 30
 
| Debur and Polish
 
| 14.50
 
| 120.00
 
|-
 
| 40
 
| Paint
 
| 15.75
 
| 120.00
 
|-
 
| 45
 
| Specialized Paint
 
| 18.00
 
| 80.00
 
|-
 
| 50
 
| Subassembly
 
| 12.25
 
| 120.00
 
|-
 
| 60
 
| Final Assembly
 
| 12.25
 
| 120.00
 
|}
 
 
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
|-
 
| '''Table Values
 
| Person.CountryRegion
 
|-
 
|}
 
 
 
 
 
{| border="1" cellpadding="5" cellspacing="0"  style="border-collapse:collapse"
 
|- style="background:silver"
 
| '''CountryRegionCode
 
| '''Name
 
|-
 
| AF
 
| Afghanistan
 
|-
 
| AL
 
| Albania
 
|-
 
| DZ
 
| Algeria
 
|-
 
| AS
 
| American Samoa
 
|-
 
| AD
 
| Andorra
 
|-
 
| AO
 
| Angola
 
|-
 
| AI
 
| Anguilla
 
|-
 
| AQ
 
| Antarctica
 
|-
 
| AG
 
| Antigua and Barbuda
 
|-
 
| AR
 
| Argentina
 
|-
 
| AM
 
| Armenia
 
|-
 
| AW
 
| Aruba
 
|-
 
| AU
 
| Australia
 
|-
 
| AT
 
| Austria
 
|-
 
| AZ
 
| Azerbaijan
 
|-
 
| BS
 
| Bahamas, The
 
|-
 
| BH
 
| Bahrain
 
|-
 
| BD
 
| Bangladesh
 
|-
 
| BB
 
| Barbados
 
|-
 
| BY
 
| Belarus
 
|-
 
| BE
 
| Belgium
 
|-
 
| BZ
 
| Belize
 
|-
 
| BJ
 
| Benin
 
|-
 
| BM
 
| Bermuda
 
|-
 
| BT
 
| Bhutan
 
|-
 
| BO
 
| Bolivia
 
|-
 
| BA
 
| Bosnia and Herzegovina
 
|-
 
| BW
 
| Botswana
 
|-
 
| BV
 
| Bouvet Island
 
|-
 
| BR
 
| Brazil
 
|-
 
| IO
 
| British Indian Ocean Territory
 
|-
 
| BN
 
| Brunei
 
|-
 
| BG
 
| Bulgaria
 
|-
 
| BF
 
| Burkina Faso
 
|-
 
| BI
 
| Burundi
 
|-
 
| KH
 
| Cambodia
 
|-
 
| CM
 
| Cameroon
 
|-
 
| CA
 
| Canada
 
|-
 
| CV
 
| Cape Verde
 
|-
 
| KY
 
| Cayman Islands
 
|-
 
| CF
 
| Central African Republic
 
|-
 
| TD
 
| Chad
 
|-
 
| CL
 
| Chile
 
|-
 
| CN
 
| China
 
|-
 
| CX
 
| Christmas Island
 
|-
 
| CC
 
| Cocos (Keeling) Islands
 
|-
 
| CO
 
| Colombia
 
|-
 
| KM
 
| Comoros
 
|-
 
| CG
 
| Congo
 
|-
 
| CD
 
| Congo (DRC)
 
|-
 
| CK
 
| Cook Islands
 
|-
 
| CR
 
| Costa Rica
 
|-
 
| CI
 
| Côte d''Ivoire
 
|-
 
| HR
 
| Croatia
 
|-
 
| CU
 
| Cuba
 
|-
 
| CY
 
| Cyprus
 
|-
 
| CZ
 
| Czech Republic
 
|-
 
| DK
 
| Denmark
 
|-
 
| DJ
 
| Djibouti
 
|-
 
| DM
 
| Dominica
 
|-
 
| DO
 
| Dominican Republic
 
|-
 
| EC
 
| Ecuador
 
|-
 
| EG
 
| Egypt
 
|-
 
| SV
 
| El Salvador
 
|-
 
| GQ
 
| Equatorial Guinea
 
|-
 
| ER
 
| Eritrea
 
|-
 
| EE
 
| Estonia
 
|-
 
| ET
 
| Ethiopia
 
|-
 
| FK
 
| Falkland Islands (Islas Malvinas)
 
|-
 
| FO
 
| Faroe Islands
 
|-
 
| FJ
 
| Fiji Islands
 
|-
 
| FI
 
| Finland
 
|-
 
| FR
 
| France
 
|-
 
| GF
 
| French Guiana
 
|-
 
| PF
 
| French Polynesia
 
|-
 
| TF
 
| French Southern and Antarctic Lands
 
|-
 
| GA
 
| Gabon
 
|-
 
| GM
 
| Gambia, The
 
|-
 
| GE
 
| Georgia
 
|-
 
| DE
 
| Germany
 
|-
 
| GH
 
| Ghana
 
|-
 
| GI
 
| Gibraltar
 
|-
 
| GR
 
| Greece
 
|-
 
| GL
 
| Greenland
 
|-
 
| GD
 
| Grenada
 
|-
 
| GP
 
| Guadeloupe
 
|-
 
| GU
 
| Guam
 
|-
 
| GT
 
| Guatemala
 
|-
 
| GN
 
| Guinea
 
|-
 
| GW
 
| Guinea-Bissau
 
|-
 
| GY
 
| Guyana
 
|-
 
| HT
 
| Haiti
 
|-
 
| HM
 
| Heard Island and McDonald Islands
 
|-
 
| HN
 
| Honduras
 
|-
 
| HK
 
| Hong Kong SAR
 
|-
 
| HU
 
| Hungary
 
|-
 
| IS
 
| Iceland
 
|-
 
| IN
 
| India
 
|-
 
| ID
 
| Indonesia
 
|-
 
| IR
 
| Iran
 
|-
 
| IQ
 
| Iraq
 
|-
 
| IE
 
| Ireland
 
|-
 
| IL
 
| Israel
 
|-
 
| IT
 
| Italy
 
|-
 
| JM
 
| Jamaica
 
|-
 
| JP
 
| Japan
 
|-
 
| JO
 
| Jordan
 
|-
 
| KZ
 
| Kazakhstan
 
|-
 
| KE
 
| Kenya
 
|-
 
| KI
 
| Kiribati
 
|-
 
| KR
 
| Korea
 
|-
 
| KW
 
| Kuwait
 
|-
 
| KG
 
| Kyrgyzstan
 
|-
 
| LA
 
| Laos
 
|-
 
| LV
 
| Latvia
 
|-
 
| LB
 
| Lebanon
 
|-
 
| LS
 
| Lesotho
 
|-
 
| LR
 
| Liberia
 
|-
 
| LY
 
| Libya
 
|-
 
| LI
 
| Liechtenstein
 
|-
 
| LT
 
| Lithuania
 
|-
 
| LU
 
| Luxembourg
 
|-
 
| MO
 
| Macao SAR
 
|-
 
| MK
 
| Macedonia, Former Yugoslav Republic of
 
|-
 
| MG
 
| Madagascar
 
|-
 
| MW
 
| Malawi
 
|-
 
| MY
 
| Malaysia
 
|-
 
| MV
 
| Maldives
 
|-
 
| ML
 
| Mali
 
|-
 
| MT
 
| Malta
 
|-
 
| MH
 
| Marshall Islands
 
|-
 
| MQ
 
| Martinique
 
|-
 
| MR
 
| Mauritania
 
|-
 
| MU
 
| Mauritius
 
|-
 
| YT
 
| Mayotte
 
|-
 
| MX
 
| Mexico
 
|-
 
| FM
 
| Micronesia
 
|-
 
| MD
 
| Moldova
 
|-
 
| MC
 
| Monaco
 
|-
 
| MN
 
| Mongolia
 
|-
 
| MS
 
| Montserrat
 
|-
 
| MA
 
| Morocco
 
|-
 
| MZ
 
| Mozambique
 
|-
 
| MM
 
| Myanmar
 
|-
 
| NA
 
| Namibia
 
|-
 
| NR
 
| Nauru
 
|-
 
| NP
 
| Nepal
 
|-
 
| NL
 
| Netherlands
 
|-
 
| AN
 
| Netherlands Antilles
 
|-
 
| NC
 
| New Caledonia
 
|-
 
| NZ
 
| New Zealand
 
|-
 
| NI
 
| Nicaragua
 
|-
 
| NE
 
| Niger
 
|-
 
| NG
 
| Nigeria
 
|-
 
| NU
 
| Niue
 
|-
 
| NF
 
| Norfolk Island
 
|-
 
| KP
 
| North Korea
 
|-
 
| MP
 
| Northern Mariana Islands
 
|-
 
| NO
 
| Norway
 
|-
 
| OM
 
| Oman
 
|-
 
| PK
 
| Pakistan
 
|-
 
| PW
 
| Palau
 
|-
 
| PS
 
| Palestinian Authority
 
|-
 
| PA
 
| Panama
 
|-
 
| PG
 
| Papua New Guinea
 
|-
 
| PY
 
| Paraguay
 
|-
 
| PE
 
| Peru
 
|-
 
| PH
 
| Philippines
 
|-
 
| PN
 
| Pitcairn Islands
 
|-
 
| PL
 
| Poland
 
|-
 
| PT
 
| Portugal
 
|-
 
| PR
 
| Puerto Rico
 
|-
 
| QA
 
| Qatar
 
|-
 
| RE
 
| Réunion
 
|-
 
| RO
 
| Romania
 
|-
 
| RU
 
| Russia
 
|-
 
| RW
 
| Rwanda
 
|-
 
| SH
 
| Saint Helena
 
|-
 
| KN
 
| Saint Kitts and Nevis
 
|-
 
| LC
 
| Saint Lucia
 
|-
 
| PM
 
| Saint Pierre and Miquelon
 
|-
 
| VC
 
| Saint Vincent and the Grenadine
 
|-
 
| WS
 
| Samoa
 
|-
 
| SM
 
| San Marino
 
|-
 
| ST
 
| São Tomé and Príncipe
 
|-
 
| SA
 
| Saudi Arabia
 
|-
 
| SN
 
| Senegal
 
|-
 
| CS
 
| Serbia and Montenegro
 
|-
 
| SC
 
| Seychelles
 
|-
 
| SL
 
| Sierra Leone
 
|-
 
| SG
 
| Singapore
 
|-
 
| SK
 
| Slovakia
 
|-
 
| SI
 
| Slovenia
 
|-
 
| SB
 
| Solomon Islands
 
|-
 
| SO
 
| Somalia
 
|-
 
| ZA
 
| South Africa
 
|-
 
| GS
 
| South Georgia and the South Sandwich Islands
 
|-
 
| ES
 
| Spain
 
|-
 
| LK
 
| Sri Lanka
 
|-
 
| SD
 
| Sudan
 
|-
 
| SR
 
| Suriname
 
|-
 
| SJ
 
| Svalbard and Jan Mayen
 
|-
 
| SZ
 
| Swaziland
 
|-
 
| SE
 
| Sweden
 
|-
 
| CH
 
| Switzerland
 
|-
 
| SY
 
| Syria
 
|-
 
| TW
 
| Taiwan
 
|-
 
| TJ
 
| Tajikistan
 
|-
 
| TZ
 
| Tanzania
 
|-
 
| TH
 
| Thailand
 
|-
 
| TL
 
| Timor-Leste
 
|-
 
| TG
 
| Togo
 
|-
 
| TK
 
| Tokelau
 
|-
 
| TO
 
| Tonga
 
|-
 
| TT
 
| Trinidad and Tobago
 
|-
 
| TN
 
| Tunisia
 
|-
 
| TR
 
| Turkey
 
|-
 
| TM
 
| Turkmenistan
 
|-
 
| TC
 
| Turks and Caicos Islands
 
|-
 
| TV
 
| Tuvalu
 
|-
 
| UM
 
| U.S. Minor Outlying Islands
 
|-
 
| UG
 
| Uganda
 
|-
 
| UA
 
| Ukraine
 
|-
 
| AE
 
| United Arab Emirates
 
|-
 
| GB
 
| United Kingdom
 
|-
 
| US
 
| United States
 
|-
 
| UY
 
| Uruguay
 
|-
 
| UZ
 
| Uzbekistan
 
|-
 
| VU
 
| Vanuatu
 
|-
 
| VA
 
| Vatican City
 
|-
 
| VE
 
| Venezuela
 
|-
 
| VN
 
| Vietnam
 
|-
 
| VG
 
| Virgin Islands, British
 
|-
 
| VI
 
| Virgin Islands, U.S.
 
|-
 
| WF
 
| Wallis and Futuna
 
|-
 
| YE
 
| Yemen
 
|-
 
| ZM
 
| Zambia
 
|-
 
| ZW
 
| Zimbabwe
 
|}
 
 
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
|-
 
| '''Table Values
 
| Person.AddressType
 
|-
 
|}
 
 
 
 
 
{| border="1" cellpadding="5" cellspacing="0"  style="border-collapse:collapse"
 
|- style="background:silver"
 
| '''AddressTypeID
 
| '''Name
 
|-
 
| 6
 
| Archive
 
|-
 
| 1
 
| Billing
 
|-
 
| 2
 
| Home
 
|-
 
| 3
 
| Main Office
 
|-
 
| 4
 
| Primary
 
|-
 
| 5
 
| Shipping
 
|}
 
 
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
|-
 
| '''Table Values
 
| HumanResources.Shift
 
|-
 
|}
 
 
 
 
 
{| border="1" cellpadding="5" cellspacing="0"  style="border-collapse:collapse"
 
|- style="background:silver"
 
| '''ShiftID
 
| '''Name
 
| '''StartTime
 
| '''EndTime
 
|-
 
| 1
 
| Day
 
| 1900-01-01 07:00:00.000
 
| 1900-01-01 15:00:00.000
 
|-
 
| 2
 
| Evening
 
| 1900-01-01 15:00:00.000
 
| 1900-01-01 23:00:00.000
 
|-
 
| 3
 
| Night
 
| 1900-01-01 23:00:00.000
 
| 1900-01-01 07:00:00.000
 
|}
 
 
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
|-
 
| '''Table Values
 
| Person.ContactType
 
|-
 
|}
 
 
 
 
 
{| border="1" cellpadding="5" cellspacing="0"  style="border-collapse:collapse"
 
|- style="background:silver"
 
| '''ContactTypeID
 
| '''Name
 
|-
 
| 1
 
| Accounting Manager
 
|-
 
| 2
 
| Assistant Sales Agent
 
|-
 
| 3
 
| Assistant Sales Representative
 
|-
 
| 4
 
| Coordinator Foreign Markets
 
|-
 
| 5
 
| Export Administrator
 
|-
 
| 6
 
| International Marketing Manager
 
|-
 
| 7
 
| Marketing Assistant
 
|-
 
| 8
 
| Marketing Manager
 
|-
 
| 9
 
| Marketing Representative
 
|-
 
| 10
 
| Order Administrator
 
|-
 
| 11
 
| Owner
 
|-
 
| 12
 
| Owner/Marketing Assistant
 
|-
 
| 13
 
| Product Manager
 
|-
 
| 14
 
| Purchasing Agent
 
|-
 
| 15
 
| Purchasing Manager
 
|-
 
| 16
 
| Regional Account Representative
 
|-
 
| 17
 
| Sales Agent
 
|-
 
| 18
 
| Sales Associate
 
|-
 
| 19
 
| Sales Manager
 
|-
 
| 20
 
| Sales Representative
 
|}
 
 
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
|-
 
| '''Table Values
 
| Production.Culture
 
|-
 
|}
 
 
 
 
 
{| border="1" cellpadding="5" cellspacing="0"  style="border-collapse:collapse"
 
|- style="background:silver"
 
| '''CultureID
 
| '''Name
 
|-
 
| ar   
 
| Arabic
 
|-
 
| zh-cht
 
| Chinese
 
|-
 
| en   
 
| English
 
|-
 
| fr   
 
| French
 
|-
 
| he   
 
| Hebrew
 
|-
 
|
 
| Invariant Language (Invariant Country)
 
|-
 
| es   
 
| Spanish
 
|-
 
| th   
 
| Thai
 
|}
 
 
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
|-
 
| '''Table Values
 
| Sales.Currency
 
|-
 
|}
 
 
 
 
 
{| border="1" cellpadding="5" cellspacing="0"  style="border-collapse:collapse"
 
|- style="background:silver"
 
| '''CurrencyCode
 
| '''Name
 
|-
 
| AFA
 
| Afghani
 
|-
 
| DZD
 
| Algerian Dinar
 
|-
 
| ARS
 
| Argentine Peso
 
|-
 
| AMD
 
| Armenian Dram
 
|-
 
| AWG
 
| Aruban Guilder
 
|-
 
| AUD
 
| Australian Dollar
 
|-
 
| AZM
 
| Azerbaijanian Manat
 
|-
 
| BSD
 
| Bahamian Dollar
 
|-
 
| BHD
 
| Bahraini Dinar
 
|-
 
| THB
 
| Baht
 
|-
 
| PAB
 
| Balboa
 
|-
 
| BBD
 
| Barbados Dollar
 
|-
 
| BEF
 
| Belgian Franc
 
|-
 
| VEB
 
| Bolivar
 
|-
 
| BOB
 
| Boliviano
 
|-
 
| BRL
 
| Brazilian Real
 
|-
 
| BND
 
| Brunei Dollar
 
|-
 
| BGN
 
| Bulgarian Lev
 
|-
 
| CAD
 
| Canadian Dollar
 
|-
 
| GHC
 
| Cedi
 
|-
 
| XOF
 
| CFA Franc BCEAO
 
|-
 
| CLP
 
| Chilean Peso
 
|-
 
| COP
 
| Colombian Peso
 
|-
 
| CRC
 
| Costa Rican Colon
 
|-
 
| HRK
 
| Croatian Kuna
 
|-
 
| CYP
 
| Cyprus Pound
 
|-
 
| CZK
 
| Czech Koruna
 
|-
 
| DKK
 
| Danish Krone
 
|-
 
| DEM
 
| Deutsche Mark
 
|-
 
| DOP
 
| Dominican Peso
 
|-
 
| VND
 
| Dong
 
|-
 
| GRD
 
| Drachma
 
|-
 
| EGP
 
| Egyptian Pound
 
|-
 
| SVC
 
| El Salvador Colon
 
|-
 
| AED
 
| Emirati Dirham
 
|-
 
| EUR
 
| EURO
 
|-
 
| FJD
 
| Fiji Dollar
 
|-
 
| HUF
 
| Forint
 
|-
 
| FRF
 
| French Franc
 
|-
 
| PYG
 
| Guarani
 
|-
 
| HKD
 
| Hong Kong Dollar
 
|-
 
| ISK
 
| Iceland Krona
 
|-
 
| INR
 
| Indian Rupee
 
|-
 
| IEP
 
| Irish Pound
 
|-
 
| ITL
 
| Italian Lira
 
|-
 
| JMD
 
| Jamaican Dollar
 
|-
 
| JOD
 
| Jordanian Dinar
 
|-
 
| KES
 
| Kenyan Shilling
 
|-
 
| EEK
 
| Kroon
 
|-
 
| KWD
 
| Kuwaiti Dinar
 
|-
 
| AOA
 
| Kwanza
 
|-
 
| LVL
 
| Latvian Lats
 
|-
 
| LBP
 
| Lebanese Pound
 
|-
 
| ALL
 
| Lek
 
|-
 
| ROL
 
| Leu
 
|-
 
| LTL
 
| Lithuanian Litas
 
|-
 
| MYR
 
| Malaysian Ringgit
 
|-
 
| MTL
 
| Maltese Lira
 
|-
 
| FIM
 
| Markka
 
|-
 
| MUR
 
| Mauritius Rupee
 
|-
 
| MXN
 
| Mexican Peso
 
|-
 
| MAD
 
| Moroccan Dirham
 
|-
 
| NGN
 
| Naira
 
|-
 
| NAD
 
| Namibia Dollar
 
|-
 
| NPR
 
| Nepalese Rupee
 
|-
 
| ANG
 
| Netherlands Antillian Guilder
 
|-
 
| NLG
 
| Netherlands Guilder
 
|-
 
| ILS
 
| New Israeli Shekel
 
|-
 
| TWD
 
| New Taiwan Dollar
 
|-
 
| NZD
 
| New Zealand Dollar
 
|-
 
| BTN
 
| Ngultrum
 
|-
 
| NOK
 
| Norwegian Krone
 
|-
 
| PEN
 
| Nuevo Sol
 
|-
 
| OMR
 
| Omani Rial
 
|-
 
| PKR
 
| Pakistan Rupee
 
|-
 
| PHP
 
| Philippine Peso
 
|-
 
| PLZ
 
| Polish Zloty(old)
 
|-
 
| PTE
 
| Portuguese Escudo
 
|-  
 
| GTQ
 
| Quetzal
 
|-
 
| ZAR
 
| Rand
 
|-
 
| MVR
 
| Rufiyaa
 
|-
 
| IDR
 
| Rupiah
 
|-
 
| RUB
 
| Russian Ruble
 
|-
 
| RUR
 
| Russian Ruble(old)
 
|-
 
| SAR
 
| Saudi Riyal
 
|-
 
| ATS
 
| Shilling
 
|-
 
| SGD
 
| Singapore Dollar
 
|-
 
| SKK
 
| Slovak Koruna
 
|-
 
| ESP
 
| Spanish Peseta
 
|-
 
| LKR
 
| Sri Lankan Rupee
 
|-
 
| SEK
 
| Swedish Krona
 
|-
 
| CHF
 
| Swiss Franc
 
|-
 
| BDT
 
| Taka
 
|-
 
| SIT
 
| Tolar
 
|-
 
| TTD
 
| Trinidad and Tobago Dollar
 
|-
 
| TND
 
| Tunisian Dinar
 
|-
 
| TRL
 
| Turkish Lira
 
|-
 
| GBP
 
| United Kingdom Pound
 
|-
 
| UYU
 
| Uruguayan Peso
 
|-
 
| USD
 
| US Dollar
 
|-
 
| KRW
 
| Won
 
|-
 
| JPY
 
| Yen
 
|-
 
| CNY
 
| Yuan Renminbi
 
|-
 
| ZWD
 
| Zimbabwe Dollar
 
|-
 
| PLN
 
| Zloty
 
|}
 
 
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
|-
 
| '''Table Values
 
| dbo.AWBuildVersion
 
|-
 
|}
 
 
 
  
{| border="1" cellpadding="5" cellspacing="0"  style="border-collapse:collapse"
+
| 10
|- style="background:silver"
+
| United Kingdom
| '''SystemInformationID
+
| GB
| '''Database Version
+
| Europe
| '''VersionDate
 
|-
 
| 1
 
| 9.06.04.26.00
 
| 2006-04-26 00:00:00.000
 
 
|}
 
|}
  

Latest revision as of 09:56, 27 August 2011

wikibot[edit]

Table Sales.SalesTerritory
Description Sales territory lookup table.

Columns[edit]

Column Data Type Nullable Default Description
TerritoryID int not null Primary key for SalesTerritory records.
Name dbo.Name not null Sales territory description
CountryRegionCode nvarchar(3) not null ISO standard country or region code. Foreign key to CountryRegion.CountryRegionCode.
Group nvarchar(50) not null Geographic area to which the sales territory belong.
SalesYTD money not null ((0.00)) Sales in the territory year to date.
SalesLastYear money not null ((0.00)) Sales in the territory the previous year.
CostYTD money not null ((0.00)) Business costs in the territory year to date.
CostLastYear money not null ((0.00)) Business costs in the territory the previous year.
rowguid uniqueidentifier not null (newid()) ROWGUIDCOL number uniquely identifying the record. Used to support a merge replication sample.
ModifiedDate datetime not null (getdate()) Date and time the record was last updated.

Primary Key[edit]

Primary Key Columns
PK_SalesTerritory_TerritoryID TerritoryID

Indexes[edit]

Index Type Columns
AK_SalesTerritory_Name Unique Name
AK_SalesTerritory_rowguid Unique rowguid

Check Constraints[edit]

Check Constraint Expression Description
CK_SalesTerritory_CostLastYear ([CostLastYear]>=(0.00)) Check constraint [CostLastYear] >= (0.00)
CK_SalesTerritory_CostYTD ([CostYTD]>=(0.00)) Check constraint [CostYTD] >= (0.00)
CK_SalesTerritory_SalesLastYear ([SalesLastYear]>=(0.00)) Check constraint [SalesLastYear] >= (0.00)
CK_SalesTerritory_SalesYTD ([SalesYTD]>=(0.00)) Check constraint [SalesYTD] >= (0.00)

Detail Tables[edit]

Detail Table Column Referencing Column
Sales.Customer TerritoryID TerritoryID
Sales.SalesOrderHeader TerritoryID TerritoryID
Sales.SalesPerson TerritoryID TerritoryID
Sales.SalesTerritoryHistory TerritoryID TerritoryID
Person.StateProvince TerritoryID TerritoryID

References[edit]

Dependency Type Object Type Referenced Object
Data Type Type dbo.Name
Schema Schema Sales

Dependencies[edit]

Reference Type Object Type Referencing Object Child Type Child Object
Select View Sales.vSalesPerson
Select View Sales.vSalesPersonSalesByFiscalYears
Update Table Sales.SalesOrderHeader Trigger uSalesOrderHeader


wikivalues[edit]

Table Values Sales.SalesTerritory
TerritoryID Name CountryRegionCode Group
1 Northwest US North America
2 Northeast US North America
3 Central US North America
4 Southwest US North America
5 Southeast US North America
6 Canada CA North America
7 France FR Europe
8 Germany DE Europe
9 Australia AU Pacific
10 United Kingdom GB Europe

automatically generated[edit]

Table Sales.SalesTerritory
Description Sales territory lookup table.


Column Data Type Nullable Default Description / PK / Index
TerritoryID int not null Primary key for SalesTerritory records.
PK_SalesTerritory_TerritoryID
Name Name not null Sales territory description
AK_SalesTerritory_Name
CountryRegionCode nvarchar(3) not null ISO standard country or region code. Foreign key to CountryRegion.CountryRegionCode.
Group nvarchar(50) not null Geographic area to which the sales territory belong.
SalesYTD money not null (0.00) Sales in the territory year to date.
SalesLastYear money not null (0.00) Sales in the territory the previous year.
CostYTD money not null (0.00) Business costs in the territory year to date.
CostLastYear money not null (0.00) Business costs in the territory the previous year.
rowguid uniqueidentifier not null (NEWID()) ROWGUIDCOL number uniquely identifying the record. Used to support a merge replication sample.
AK_SalesTerritory_rowguid
ModifiedDate datetime not null (GETDATE()) Date and time the record was last updated.


Detail Table Column Referencing Column
Sales.Customer TerritoryID TerritoryID
Sales.SalesOrderHeader TerritoryID TerritoryID
Sales.SalesPerson TerritoryID TerritoryID
Sales.SalesTerritoryHistory TerritoryID TerritoryID
Person.StateProvince TerritoryID TerritoryID


Dependency Type Object Type Referenced Object
Data Type Type dbo.Name
Schema Schema Sales


Reference Type Object Type Referencing Object Child Type Child Object
Select View Sales.vSalesPerson
Select View Sales.vSalesPersonSalesByFiscalYears
Update Table Sales.SalesOrderHeader Trigger uSalesOrderHeader