Passing values for multi-value parameter in SSRS query string

Jamie picture Jamie · Aug 11, 2009 · Viewed 37.7k times · Source

I have two reports built using SSRS 2005. The first report is set to navigate to the second when a specific field is clicked. I am using an expression similar to the following in the "Jump to URL" property of the textbox:

="javascript:void(window.open('http://server/reportserver?%2fFolder%2fMyReport&rs:Command=Render&Date=" & Fields!Date.Value & "&MachineId=" & Fields!Machine.Value & "'))"

There is a multi-value parameter on the second report. I need to pass multiple values for this parameter in the URL query string when calling this report. Is there a way to pass multiple values for a parameter in the query string of a report? Or can you pass a parameter that will cause the Select All value to be selected?

Thanks.

Answer

Mitch picture Mitch · Aug 11, 2009

Just add additional query string parameters.

For example, to pass the parameters

Date:       2009-06-01
MachineID:  Machine1, Machine2, Machine3, Machine4

to a report named Folder\MyReport on a server named server, you would use the URL:

http://server/reportserver?%2fFolder%2fMyReport&rs:Command=Render&Date=2009-06-01&MachineId=Machine1&MachineId=Machine2&MachineId=Machine3&MachineId=Machine4