Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Report Parameter Help
angiem
Hello
I'm a new user of Birt and want to know how to use a dropdown box to select either all products or an individual product from the dropdown box in a report and filter on this.
Thanks
Angie
Find more posts tagged with
Comments
mwilliams
Hi Angie,
Suppose your query is:
select * from products
You would create a second dataSet for your parameter select with a query like:
select productName from products
Then, you'd create a list parameter tied to the second query above and make the default value "All". Then, in the beforeOpen script of the first dataSet above, you'd put the following script:
if (params["paramName"] != "All"){
this.queryText = this.queryText + " where productName = '" + params["paramName"] + "'";
}
Hope this helps. Let me know if you have questions.