2016-05-12 110 views
0

我經過一個教程hierachyid和他們解釋他們使用下面的查詢上advantureworks2012瞭解adventureworks2012 DB結構

Select * From HumanRessources.Employee 

我生成的圖表,可以發現一個表中調用員工,但沒有HumanRessources之一。 enter image description here

我試圖找到AW2012 db的文檔,但只能找到其中沒有HumanRessourcesAW2008之一。

我的問題:什麼是HumanRessources,因爲它不是一個表我不明白它是什麼以及它是如何實現的?

+0

貌似模式被稱爲「人力資源」,這是代替通常的「DBO」 –

+0

的是架構。 http://blog.sqlauthority.com/2009/09/07/sql-server-importance-of-database-schemas-in-sql-server/ – granadaCoder

回答

0

HumanResources確實是架構,其中Employee是表名。

,你會因此查詢使用SELECT * FROM HumanResources.Employee;

你可能會在這裏找到有用的官方數據字典表:https://technet.microsoft.com/en-us/library/ms124438(v=sql.100).aspx

另外,請看下圖的的AdventureWorks2008數據庫的概述(它幾乎等同於2012 )。注意陰影區域代表不同的模式。

Adventureworks2008 ER Diagram