Reporting Services 2008: User Usage! Userid in parameters

I have a report with a parameter that is populated with a list of sales representatives returned by the request. I want to filter this list based on the security rights of the user running the report.

To fulfill the request, I need to pass user! userID in db. I tried something like this:

... where UserName = user! UserID ...

But he doesn't like the syntax.

+4
source share
3 answers

Change your request to:

where UserName = @user 

... and on the Options tab, assign "User! UserID" to the "@user" parameter.

+10
source

I just want to share my experience if some poor soul wanders around like me without any clue. I found that my @user parameter had to be first on the list so that my drop-down menu was populated, which depended on it. I do not know why.

+2
source

Yes. I can confirm that the order is important when using the user ID in the request to set the default value for another parameter. I had to delete and recreate the parameters to make it work. I could not see a way to move the order of the parameters

0
source

All Articles