Give only that particular UserID accessed stores in the dropdown for my SSRS Report

reddy421 26 Reputation points
2021-10-05T16:32:35.303+00:00

I have an SSRS report which gives the sales by employee.
The Parameters I have are
-> StartDate
-> EndDate
-> StoreName

I created this Report and Deployed it to the Report Manager.
Created an AD Group for the HR Team and gave Read Access to the AD Group and they are able to access it.
This is all fine but Now I am thinking of using the same report to the Store Managers also.
There are around 400 Stores and when a Manger of a store logins with the Store Generic ID, I wanted him to have access to only that Particular Store in the Store DropDown.
He should not be able to see the other stores in the StoreDropDown.
Any suggestions on how to do this?

SQL Server Reporting Services
SQL Server Reporting Services
A SQL Server technology that supports the creation, management, and delivery of both traditional, paper-oriented reports and interactive, web-based reports.
2,813 questions
0 comments No comments
{count} votes

3 answers

Sort by: Most helpful
  1. Isabellaz-1451 3,616 Reputation points
    2021-10-06T01:50:40.397+00:00

    Hi @reddy421 ,

    You can create 400 linked reports , then set each report parameter to a default value , then open each linked report to each store. Howerver, there are 400 stores, the work will be huge. I would like recommend another method to you,it is the data driven subscription , please refer to this link:create-a-data-driven-subscription-ssrs-tutorial

    If you have questions during creating subscription,please feel free to contact me.

    Best Regards,
    Isabella


    If the answer is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

  2. Olaf Helper 41,001 Reputation points
    2021-10-07T07:23:51.827+00:00

    You have to implement a kind of row-level security.
    Create a table with mapping username <=> store id and use it to filter the store, where the current user do have permissions for.

    0 comments No comments

  3. Isabellaz-1451 3,616 Reputation points
    2021-10-21T09:56:24.653+00:00

    Hi @reddy421 ,
    Olaf 's method is feasible,I will give you detail steps,hope will help you.

    1.Create parameter userID ,set it's default value =User!UserID , later you can hide the parameter

    142424-create-parameter.png

    142443-set-default-value.png

    2.Create mapping table ,username -> storename

    142461-create-mapping.png

    3.Create storelist dataset which can filtered by userID

    select store from mapping where username =@UserID  
    

    Best Regards,
    Isabella


    If the answer is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments