Toggle Between Single and Multivalued Parameter

  • Hi

    I have a report in SSRS 2005, where i need to toggle between single and multivalued parameters. I should have 2 options 'SINGLE' and 'MULTI', based on them i need to toggle the parameters type.

    I don't find this feature in SSRS. I heard that this may be possible using .NET code. Please tell me how can we achieve this? Please Help!!!

    Thanks

  • Out of curiosity, why would you need to switch btw single and mult? Can't your users just select a single value from the multi-value dropdown?

  • Hi

    The end users either want to provide a value manually or they might select multiple values from multi-valued parameter.

    Its all about the requirement dude....:-)

    Thanks

  • Requirements. Gotcha.

    I don't have an elegant solution, but you could add both a single and a multi parameter to the report and make them both nullable. Then in your query do something like this:

    .

    .

    .

    WHERE (field_1 = @single OR @single IS NULL)

    AND ((field_1 IN (@multi) OR @multi IS NULL)

    That would return all if the user ran the report with both parameters as null though.

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply