我正试图在多个表格中填写一个PIVOT(管理服务器2008年),没有涉及总的功能。 我在这里的深 to中不得不坦率地讲我,在努力确定问题的时候,我只想跳跃,向你们展示我的 st(oo),首先,我有三张表格:
CHARTER_vessels
===============
vesselID vesselName
-------- ----------
1 The Titanic
2 The Pinafore
3 The Black Pearl
CHARTER_rateDateRange
=====================
rateDateRangeID rateDateRangeName
--------------- -----------------
1 Spring 2012
2 Summer 2012
3 Fall 2012
CHARTER_rates
=============
vesselID rateDateRangeID rateCost
-------- --------------- --------
1 1 434
1 2 445
1 3 231
2 1 675
2 2 545
2 3 768
3 1 543
3 2 654
3 3 658
And the output I m trying to achieve is that the rates for each boat appear in the column for each season, like this:
vesselName Spring 2012 Summer 2012 Fall 2012
---------- ----------- ----------- ---------
The Titanic 434 445 231
The Pinafore 675 545 768
The Black Pearl 543 654 658
显然,我希望能够尽可能区分不同栏目确定的结果!