Friday, March 9, 2012

Parameters in URL - Problem

Hi,

I am new to Reporting services and have managed to create some reports. I want to pass some parameters in the URL to the report. I know how to do this but some parameters are not passing to the parameter boxes. They are clearly displayed in the URL but are not populating the boxes. I have one report done before i came and this used to work but now it doesnt work.

Any ideas?

Matt

Hi Matt,

i am unable to understand ur prob completely. But still, if the parameter field is a dropdown list, then the value for that parameter passed in the URL should exists in the dropdown list or else the report will throw an error.

Cheers

Chakri.

|||

Try the sample reports available with your installation of SQL Server. They should show you how to do this:

http://msdn2.microsoft.com/en-us/library/ms161542.aspx

Hope that helps,

-Lukasz

|||

Hi All,

I have the similar kind of problem where i can't see the parameters and their values.

I have a simple report where i am passing employeeid as parameter. When i run it on the server it prompt me for employeeid which after giving displays the report but in the url of browser , i cannot see the parameter and it's value .

Anybody has any idea why this is happenning.

Thanks,

Nagul Shaik

|||

We do not show the parameter in the URL when you're using the report viewer. It does not matter, the report is receiving the parameter.

To see what value the report is receiving you can add a textbox to the report and set it's value to:

=ReportParameters!ParameterName.Value

Hope that helps,

-Lukasz

|||

thanks for the reply but i am not using any report viewer. I am trying access the report thru browser giving the parameters in query string instead of in the prompt.

My requirement is to create hyperlink in my aspx page for that report and when the logged in user clicks on it , i have to pass userid to that report to show the contents of the report.

My sql2005 reporting service is running on WIN2K3.

Please help me with it.

|||

This topic in books online provides you the starting point for how to construct URLs understood by the report server.

http://msdn2.microsoft.com/de-de/library/ms155362.aspx

to pass a particular parameter you defined in the report, you can just append <parametername>=<value> to the end of the query string.

The User!UserId global variable is not a parameter - it is determined by who is logged into the report server. You cannot control it on the URL itself.

Hope that helps,

-Lukasz

|||

http://msdn2.microsoft.com/en-us/library/ms153586(SQL.90).aspx

No comments:

Post a Comment