Database reference - AdventureWorks

AdventureWorks -  tables -  [Sales].[Currency]

Description

Lookup table containing standard ISO currencies. 

Table properties

namevalue
name[Sales].[Currency]
createdMar 19 2009 9:08PM
modifiedMar 19 2009 9:08PM 
ansi nullson 
quoted identifieron 
row count105
Size of data8 kb
Size of indexes24 kb
Maximum size of a single row220 bytes

Columns

columndatatypelengthbytesdefaultnullsPKFKUQcomputedcomment
CurrencyCodenchar(3)312 no  yes    no  The ISO code for the Currency. 
NameName50200 no      no  Currency name. 
ModifiedDatedatetime238(getdate())no      no  Date and time the record was last updated. 

Indexes

namedescriptioncolumncomment
AK_Currency_Namenonclustered, unique located on PRIMARYNameUnique nonclustered index. 
PK_Currency_CurrencyCodeclustered, unique, primary key located on PRIMARYCurrencyCodeClustered index created by a primary key constraint. 

Referenced by

name
CountryRegionCurrency
CurrencyRate
CurrencyRate

Foreign key graph

CurrencyCountryRegionCurrencyCurrencyRateCurrencyRate

Defaults

default namecolumncomment
DF_Currency_ModifiedDateModifiedDateDefault constraint value of GETDATE() 

Dependency graph

DF_Currency_ModifiedDateNameCurrencyAK_Currency_NamePK_Currency_CurrencyCode

Objects that [Sales].[Currency] depends on

nameobject typelevel
Nametype1

Sample rows

CurrencyCodeNameModifiedDate
AED  Emirati Dirham  6/1/1998 12:00:00 AM 
AFA  Afghani  6/1/1998 12:00:00 AM 
ALL  Lek  6/1/1998 12:00:00 AM 
AMD  Armenian Dram  6/1/1998 12:00:00 AM 
ANG  Netherlands Antillian Guilder  6/1/1998 12:00:00 AM 
AOA  Kwanza  6/1/1998 12:00:00 AM 
ARS  Argentine Peso  6/1/1998 12:00:00 AM 
ATS  Shilling  6/1/1998 12:00:00 AM 
AUD  Australian Dollar  6/1/1998 12:00:00 AM 
AWG  Aruban Guilder  6/1/1998 12:00:00 AM 

Code

CREATE TABLE [Sales].[Currency](
    [CurrencyCode] [nchar](3) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
    [Name] [dbo].[Name] NOT NULL,
    [CurrencyCode] [nchar](3) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
    [ModifiedDate] [datetime] NOT NULL,
 CONSTRAINT [PK_Currency_CurrencyCode] PRIMARY KEY CLUSTERED 
(
    [CurrencyCode] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY]

ALTER TABLE [Sales].[Currency] ADD  CONSTRAINT [DF_Currency_ModifiedDate]  DEFAULT (getdate()) FOR [ModifiedDate]

Powered by Yoyodyne © 1971