Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
THRUST SERVICES & TOOLS
CLOUD EDITIONS
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Dynamic, variable length Report Param generation?
baeman
Hi,
I am trying to produce a line chart.
Given x number of results in a database column, I would like to dynamically generate a report parameter to accept a value for each distinct value in this column.
I'll try to ellaborate with an example:
Given a table, "Fruit", which contains three columns "Name", "Colour", "Days before fruit turns bad" and, say, 4 rows. The value in the "Colour" column contains 3 distinct values, "red", "yellow", "green".
I would like to have a report parameter for each one, where the user can type in a piece of numeric data, such as:
"How many days until you realistically expect the <<red>> fruit to turn bad?"
"How many days until you realistically expect the <<yellow>> fruit to turn bad?"
"How many days until you realistically expect the <<green>> fruit to turn bad?"
The value would then be printed as a line parallel to the x axis across the linechart: The graph would communicate the actual days elapsed until the fruit turned bad, compared to the user's expectation.
Now, I understand how to create said line using the Chart API, but I don't know how to engineer the report such that the report parameters offered are dynamic?
Rather than produce a static report parameter for each colour, I would like something slicker that will pick up each distinct colour from this table, and generate the report parameters for me (so, if a fifth row for a blue piece of fruit is added to the table, a report parameter for blue fruit would appear:
"How many days until you realistically expect the <<blue>> fruit to turn bad?"
)
Is this possible? I've looked around the forum and googled, but no success so far.
Thanks
Find more posts tagged with
Comments
mwilliams
Hi baeman,
If I understand your question correctly, if you had two dataSets, one with just the "colors" of fruit, and a second with all of the data limiting the color with a dataSet parameter, you could link a table to the first dataSet and embed a table within that table linked to the second dataSet. You'd use the dataSet parameter binding button on the binding tab for the inner table to link the inner and outer tables. Your chart would then be in the inner table and would use the container as the source.
Since the outer table is linked to a dataSet that grabs all distinct colors, if you added a new color to your database, it would still be queried to make your chart out of.
Hope this helps. Let me know if you have questions.