Red Swan
Red Swan

Reputation: 15545

Using dropdown parameters in SSRS report

I can see the text box for my data set that having the

"select col1 from table name " as query. I want to populate dropdown instead of text box. I have created the parameter for it . what to do?

Upvotes: 14

Views: 72647

Answers (5)

Aaron Lelevier
Aaron Lelevier

Reputation: 20760

My solution:

  1. Right click the parameter under the "Report Data" and select "Parameter Properties"

  2. Select "Available Values" section

  3. Click the "Get values from a query" option

4a. Select the appropriate query to use

4b. Select the Value that you want the main query to use to generate the data

4c. Select the Label that will show in the drop down box that the User sees and selects a option from

Upvotes: 7

pollifax
pollifax

Reputation: 51

If you already deployed a previous version of your report, for some reason this kind of parameter change doesn't get picked up when you redeploy. Try deleting the report using Report Manager, then redeploy.

Upvotes: 2

shruti
shruti

Reputation: 21

follow these steps 1.In the Report Data pane, expand the Parameters node and right-click on the parameter, then click Parameter Properties.

2.In Prompt, type Select :.

3.In Data type, select datatype.

4.Click Available Values.

5.Select the Get values from a query option.

6.select value field and Label field

7.In default values select Get values from a query option. 8.From the Dataset drop-down list, select BusinessPersons.

9.From the Value field drop-down list, select BusinessEntityID.

10.Click OK.

Upvotes: 2

Nat
Nat

Reputation: 14295

In short

  1. Right click the parameter

  2. Select "Available Values" section

  3. Click the "Get values from a query" option

  4. Select the appropriate dataset and fields

Upvotes: 26

NakedBrunch
NakedBrunch

Reputation: 49413

This following articles cover exactly what you need to know about setting report parameters in SSRS:

Upvotes: 5

Related Questions