Akameriadoc
Akameriadoc

Reputation: 3

One Parameter Selection = Multiple Parameters Selected SSRS/SQL

In SSRS I am looking to create a report that has a selection for location. I would also like to add regions so that groups of locations can be selected easily. Preferably this selection would come out as its own line in the report as well. Any suggestions on how to make this possible?

I am also looking to create a selection for All that use all the locations and create a single line in the report.

Upvotes: 0

Views: 84

Answers (1)

M.Ali
M.Ali

Reputation: 69494

you will need three data sets

  1. Dataset for Locations

    select distinct locations and populate your Locations Parameter's drop down, in parameter properties allow multiple values to be selected. Also for default value select values from query which will bring all the locations forward.

  2. Dataset for Regions

    This parameters's drop down will be populated by the Locations selected from 1st locations Parameter something like

     SELECT DISTINCT Regions
     FROM TABLE
     WHERE (Locations IN (@Locations))
    
  3. Main Dataset

    Finally this will be the main dataset for your report which will pull data where regions are in Regions selected in your Regions parameter. something like

     SELECT *
     FROM TABLE
     WHERE (Regions IN (@Regions))
    

Upvotes: 1

Related Questions