|
Re: Parameter that decides wich table show [message #704570 is a reply to message #704506] |
Thu, 28 July 2011 19:32 |
|
If you have a small number of tables then why not add them all and then
name them. Then in the beforeFactory drop the ones you do not need.
reportContext.getDesignHandle().findElement("mytable1" ).drop();
This is simpler than calling the de api to change a tables bindings.
Jason
On 7/28/2011 2:01 PM, josete4ever wrote:
> Hello BIRT comunity,
> I'm quite new into BIRT; I am developing a report that shows the content
> of a database table which is selected by a parameter in a previous JSP
> page.
> I have modified the "this.queryText" within the beforeOpen event in the
> dataset (
> this.queryText.replace("TABLENAME",parms["MYPARAMETER"].value)") And I
> just get the data I really want from the table I selected, but I don't
> know how to "print it" into the report, if I just draw a table within
> the layout view I got the following message
>
> Column binding "CUSTOMERNUMBER" has referred to a data set column
> "CUSTOMERNUMBER" which does not exist. (Element ID:967)
>
> because the name of the columns do not match with the name of the
> supossed table I selected (for example ORDERS)
> I also tried to change the column data binding expression like this
>
> if (parms["MYPARAMETER"] =table1)
> {
> setDataRow["Rowoftable1"]
> }
>
> if (parms["MYPARAMETER"] =table2)
> {
> setDataRow["Rowoftable2"]
> }
>
> but It doesn't work neither
>
>
> So, in a nutshell, how can I show in a table the content of a
> "parametrized DataSet" wich I don't know the name of the columns in
> advance ?
> Thank you very much
>
>
|
|
|
|
Re: Parameter that decides wich table show [message #705261 is a reply to message #705249] |
Fri, 29 July 2011 16:16 |
|
Sounds good, but remember hidden tables still run queries.
Jason
On 7/29/2011 12:08 PM, josete4ever wrote:
> Thanks for your response, at the end of the day what i did is to change
> the expression for visibility of some tables in the report like this:
> Visible if ---> params["TableName"].value != "ParameterTableName"
>
> :blush:
> Thank for your response.
|
|
|
|
Powered by
FUDForum. Page generated in 0.04076 seconds