Dynamic Graph and Filters in SSRS 2008
Anybo开发者_开发百科dy knows? Even an "it isn't possible" answer is a good one : )
Hi there,
To begin with - I'm using SSRS 2008 (not R2), report builder 2.0 and a report model.
I want to create dynamic graphs, i.e., to enable the end-user to decide which graph he wants to see - what are the x and y axes.
I'll try to make it simple - let's say my report model have some properties: prop1 prop2 prop3 .....
i want to use a report parameter to enable the user to choose which propery he wants to use as the x axis, and another parameter to enable him to choose the y axis. Populating the available values for the parameters is quite easy. The problem begins when i want to actually create the report :) Since the number of available properties is big, I don't think that using iif statments or hidden/visible properties is the right approach.
Any ideas?
Hope I made myself clear, and thanks in advance for any help!
I work in BIDS, so I'm not sure how much of this will transfer to Report Builder, but seeing as you haven't gotten any responses in a couple days.
Can you modify your dataset? Create calculated fields based on the parameter. You can create these in a Report Model, and in BIDS, these can be based on a parameter. Hopefully you can do this in Report Builder. The field might be named something like "AxisX." Within the definition of the field, have an iif statement that will return whichever other field is appropriate based on the parameter.
Calculated fields in Report Builder: http://msdn.microsoft.com/en-us/library/ms345330.aspx
Hmmm, if this was a requirement I'd probably try and do as much as possible in the query, and make sure it's a simple dataset returned e.g.
IF @param1 = 'something'
SELECT val = somefield,
measure = 'sometext'
FROM x
ELSEIF @param1 = 'another'
SELECT val = anotherfield,
measure = 'anothertext'
FROM x
(The code above won't work; it's just an outline of what a query might look like)
精彩评论