Fatemeh Shakhsesalim
Fatemeh Shakhsesalim

Reputation: 51

Hiding some columns based on who is viewing the data, SSRS

I have a SSRS report that contains both cost and price of products. What I want to do is based on who is viewing the report hide or show costs. price will always display. I spent some time online, but I got lost. I am new to this topic and don't know where to start. Any help is appreciated.

Upvotes: 0

Views: 824

Answers (1)

William Xu
William Xu

Reputation: 261

I can think of 2 ways:

  1. Have 2 (or more) versions of this report --- one has the column hidden, the other one has it visible. Then put these 2 reports in different folder on SSRS server, set different access to the folders for your target audience groups accordingly. My company is using this way to solve the problem.
  2. Create a hidden parameter to read the user's ID (by setting the default value to be User!UserID). Then set the visibility of the column to be based on the value of this parameter. That's my basic idea. (To implement, you may need another Boolean parameter and several datasets of your user group) But the drawback of this solution is that hiding a column is not like hiding a group --- it may look very weird sometimes, not the way you want them to be at all.

Upvotes: 1

Related Questions