Difference between revisions of "HumanResources.vEmployee (view)"
(7 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" |
− | | ''' | + | | '''View |
| HumanResources.vEmployee | | HumanResources.vEmployee | ||
− | |- | + | |- valign="top" |
+ | | '''Description | ||
+ | | Employee names and addresses. | ||
|} | |} | ||
+ | === Source === | ||
<pre> | <pre> | ||
CREATE VIEW [HumanResources].[vEmployee] | CREATE VIEW [HumanResources].[vEmployee] | ||
Line 41: | Line 44: | ||
ON cr.[CountryRegionCode] = sp.[CountryRegionCode]; | ON cr.[CountryRegionCode] = sp.[CountryRegionCode]; | ||
</pre> | </pre> | ||
+ | |||
+ | === References === | ||
+ | {| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse" | ||
+ | |- style="background:silver" | ||
+ | | '''Dependency Type | ||
+ | | '''Object Type | ||
+ | | '''Referenced Object | ||
+ | |||
+ | |- valign="top" | ||
+ | | Select | ||
+ | | Table | ||
+ | | [[HumanResources.Employee_(table)|HumanResources.Employee]] | ||
+ | |||
+ | |- valign="top" | ||
+ | | Select | ||
+ | | Table | ||
+ | | [[HumanResources.EmployeeAddress_(table)|HumanResources.EmployeeAddress]] | ||
+ | |||
+ | |- valign="top" | ||
+ | | Select | ||
+ | | Table | ||
+ | | [[Person.Address_(table)|Person.Address]] | ||
+ | |||
+ | |- valign="top" | ||
+ | | Select | ||
+ | | Table | ||
+ | | [[Person.Contact_(table)|Person.Contact]] | ||
+ | |||
+ | |- valign="top" | ||
+ | | Select | ||
+ | | Table | ||
+ | | [[Person.CountryRegion_(table)|Person.CountryRegion]] | ||
+ | |||
+ | |- valign="top" | ||
+ | | Select | ||
+ | | Table | ||
+ | | [[Person.StateProvince_(table)|Person.StateProvince]] | ||
+ | |||
+ | |- valign="top" | ||
+ | | Schema | ||
+ | | Schema | ||
+ | | [[HumanResources_(schema)|HumanResources]] | ||
+ | |||
+ | |} | ||
+ | |||
== automatically generated == | == automatically generated == | ||
Line 48: | Line 96: | ||
| '''view | | '''view | ||
| HumanResources.vEmployee | | HumanResources.vEmployee | ||
− | |- | + | |- valign="top" |
− | |||
| '''Description | | '''Description | ||
| Employee names and addresses. | | Employee names and addresses. | ||
|- | |- | ||
− | |||
|} | |} | ||
Line 90: | Line 136: | ||
ON cr.[CountryRegionCode] = sp.[CountryRegionCode]; | ON cr.[CountryRegionCode] = sp.[CountryRegionCode]; | ||
</pre> | </pre> | ||
+ | |||
+ | |||
+ | {| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse" | ||
+ | |- style="background:silver" | ||
+ | | '''Dependency Type | ||
+ | | '''Object Type | ||
+ | | '''Referenced Object | ||
+ | |||
+ | |- | ||
+ | | Select | ||
+ | | Table | ||
+ | | [[HumanResources.Employee_(table)|HumanResources.Employee]] | ||
+ | |||
+ | |- | ||
+ | | Select | ||
+ | | Table | ||
+ | | [[HumanResources.EmployeeAddress_(table)|HumanResources.EmployeeAddress]] | ||
+ | |||
+ | |- | ||
+ | | Select | ||
+ | | Table | ||
+ | | [[Person.Address_(table)|Person.Address]] | ||
+ | |||
+ | |- | ||
+ | | Select | ||
+ | | Table | ||
+ | | [[Person.Contact_(table)|Person.Contact]] | ||
+ | |||
+ | |- | ||
+ | | Select | ||
+ | | Table | ||
+ | | [[Person.CountryRegion_(table)|Person.CountryRegion]] | ||
+ | |||
+ | |- | ||
+ | | Select | ||
+ | | Table | ||
+ | | [[Person.StateProvince_(table)|Person.StateProvince]] | ||
+ | |||
+ | |- | ||
+ | | Schema | ||
+ | | Schema | ||
+ | | [[HumanResources_(schema)|HumanResources]] | ||
+ | |||
+ | |} |
Latest revision as of 23:16, 23 June 2010
wikibot[edit]
View | HumanResources.vEmployee |
Description | Employee names and addresses. |
Source[edit]
CREATE VIEW [HumanResources].[vEmployee] AS SELECT e.[EmployeeID] ,c.[Title] ,c.[FirstName] ,c.[MiddleName] ,c.[LastName] ,c.[Suffix] ,e.[Title] AS [JobTitle] ,c.[Phone] ,c.[EmailAddress] ,c.[EmailPromotion] ,a.[AddressLine1] ,a.[AddressLine2] ,a.[City] ,sp.[Name] AS [StateProvinceName] ,a.[PostalCode] ,cr.[Name] AS [CountryRegionName] ,c.[AdditionalContactInfo] FROM [HumanResources].[Employee] e INNER JOIN [Person].[Contact] c ON c.[ContactID] = e.[ContactID] INNER JOIN [HumanResources].[EmployeeAddress] ea ON e.[EmployeeID] = ea.[EmployeeID] INNER JOIN [Person].[Address] a ON ea.[AddressID] = a.[AddressID] INNER JOIN [Person].[StateProvince] sp ON sp.[StateProvinceID] = a.[StateProvinceID] INNER JOIN [Person].[CountryRegion] cr ON cr.[CountryRegionCode] = sp.[CountryRegionCode];
References[edit]
Dependency Type | Object Type | Referenced Object |
Select | Table | HumanResources.Employee |
Select | Table | HumanResources.EmployeeAddress |
Select | Table | Person.Address |
Select | Table | Person.Contact |
Select | Table | Person.CountryRegion |
Select | Table | Person.StateProvince |
Schema | Schema | HumanResources |
automatically generated[edit]
view | HumanResources.vEmployee |
Description | Employee names and addresses. |
CREATE VIEW [HumanResources].[vEmployee] AS SELECT e.[EmployeeID] ,c.[Title] ,c.[FirstName] ,c.[MiddleName] ,c.[LastName] ,c.[Suffix] ,e.[Title] AS [JobTitle] ,c.[Phone] ,c.[EmailAddress] ,c.[EmailPromotion] ,a.[AddressLine1] ,a.[AddressLine2] ,a.[City] ,sp.[Name] AS [StateProvinceName] ,a.[PostalCode] ,cr.[Name] AS [CountryRegionName] ,c.[AdditionalContactInfo] FROM [HumanResources].[Employee] e INNER JOIN [Person].[Contact] c ON c.[ContactID] = e.[ContactID] INNER JOIN [HumanResources].[EmployeeAddress] ea ON e.[EmployeeID] = ea.[EmployeeID] INNER JOIN [Person].[Address] a ON ea.[AddressID] = a.[AddressID] INNER JOIN [Person].[StateProvince] sp ON sp.[StateProvinceID] = a.[StateProvinceID] INNER JOIN [Person].[CountryRegion] cr ON cr.[CountryRegionCode] = sp.[CountryRegionCode];
Dependency Type | Object Type | Referenced Object |
Select | Table | HumanResources.Employee |
Select | Table | HumanResources.EmployeeAddress |
Select | Table | Person.Address |
Select | Table | Person.Contact |
Select | Table | Person.CountryRegion |
Select | Table | Person.StateProvince |
Schema | Schema | HumanResources |