2013-12-16 108 views
0

我有一個數據表創建RTF模板,XML BI Publisher報表

model day number 
GS  1   0 
LX  1   0 
ES  1   1 
GS  2   0 
LX  2   0 
ES  2   0 
GS  3   0 
LX  3   1 
ES  3   0 
      31   0 

請幫我創建RTF模板來顯示數據:

Model  1  2  3  4  5  6  7 31  total 
GS  0  0  0  0  0  0  0  0   0 
LX  0  0  1  0  0  0  0  0   1 
ES  1  0  0  0  0  0  0  0   0 
Total  1  0  0  0  0  0  0  0   1 
+0

嗨,我嘗試和結果: 模型1 2 3 4 5 6 7 31總 GS 0 0 0 0 0 0 0 0 0 LX 0 0 1 0 0 0 0 0 0 ES 0 0 0 0 0 0 0 0 0 總計0 0 0 0 0 0 0 0 0 – user3107728

+0

collum num is 0>。< – user3107728

回答

0

聽起來好像要交叉表數據。

Oracle的XML發佈報告設計手冊裏有關於如何做到這一點的詳細信息:

XML數據

<ROWSET> 
<RESULTS> 
<INDUSTRY>Motor Vehicle Dealers</INDUSTRY> 
<YEAR>2005</YEAR> 
<QUARTER>Q1</QUARTER> 
<SALES>1000</SALES> 
</RESULTS> 
<RESULTS> 
<INDUSTRY>Motor Vehicle Dealers</INDUSTRY> 
<YEAR>2005</YEAR> 
<QUARTER>Q2</QUARTER> 
<SALES>2000</SALES> 
</RESULTS> 
<RESULTS> 
<INDUSTRY>Motor Vehicle Dealers</INDUSTRY> 
<YEAR>2004</YEAR> 
<QUARTER>Q1</QUARTER> 
<SALES>3000</SALES> 
</RESULTS> 
<RESULTS> 
<INDUSTRY>Motor Vehicle Dealers</INDUSTRY> 
<YEAR>2004</YEAR> 
<QUARTER>Q2</QUARTER> 
<SALES>3000</SALES> 
</RESULTS> 
<RESULTS> 
<INDUSTRY>Motor Vehicle Dealers</INDUSTRY> 
<YEAR>2003</YEAR> 
... 
</RRESULTS> 
<RESULTS> 
<INDUSTRY>Home Furnishings</INDUSTRY> 
... 
</RESULTS> 
<RESULTS> 
<INDUSTRY>Electronics</INDUSTRY> 
... 
</RESULTS> 
<RESULTS> 
<INDUSTRY>Food and Beverage</INDUSTRY> 
... 
</RESULTS> 
</ROWSET> 

Word模板詳細

MS Word Details 1

MS Word Details 2

MS Word Details 3

結果:

Results