Search code examples
reporting-servicesssrs-2008ssrs-tablix

Default Value Based on a Label


I have created a report with a few different parameters in SSRS.

I have the available values for each parameter based off a corresponding dataset (which creates a drop-down).

If I have one parameter that has 10 different options as a drop down. How can I create the default value equal to specific options.

For example I have a report with the following fields:

Name - Age - Gender

I would like the default to be where Age IN (25, 30, 34). How can I go about this?

Any input is greatly appreciated.


Solution

  • This is actually an easy thing to do.

    Open the Properties dialog Age parameter while in design mode.

    Go to the Default Values sheet, and choose the Specify values option. Then, in the Value section of that sheet, Add a value for each age that you want to use as a default; one value per line in the Value section.

    For this to work as expected, you will have to check the Allow multiple values option on the General sheet of the same dialog. Choosing that turn a parameter into an IN parameter.

    Hope this helps you out.