2012-09-11 51 views
0

我的問題是相同的這個問題BIRT報表多輸入參數

here

我想在這個問題的解決方案,但如果所有的參數的值設爲它只能工作,但如果沒有價值伯特報告輸出此錯誤

The following items have errors: 
Table (id = 4): 
+ Can not load the report query: 4. Errors occurred when generating the report document for the report element with ID 4. (Element ID:4) 

你們能幫我嗎?

感謝

回答

1

在當參數沒有從你放什麼在查詢文本框中的值查詢不修改的例子。你也可以這樣做: 1把查詢像SELECT * FROM MYTABLE 2 - 然後把一個beforeOpen腳本,如:

if(params["myparameterval"]){ 
     this.queryText = this.queryText + " where col1 = " + params["myparameterval"].value; 
    }else{ 
     this.queryText = this.queryText + " where col1 = hardcodedvalue" 
    }