user459874
user459874

Reputation: 11

SQL Reporting Services Boolean Parameter (True/False/All(?))

I have a SSRS report that works with boolean parameter. I would like to add a third option to show all the records on the report. Both true and false. The concept is that the dropdown will include three options (All,True,False).

Is there a way to acheive that?

Thanks,

-Y

Upvotes: 1

Views: 11918

Answers (2)

Gabriel G
Gabriel G

Reputation: 700

Select Allow multiple values:

enter image description here

Then add the desired values:

enter image description here

Then add a new filter and convert the field value to String:

enter image description here

Then select the IN operator:

enter image description here

Upvotes: 1

IMITAZ
IMITAZ

Reputation: 21

Set the dataset filter to something like this:

I have 3 available values for @parmTRUEFALSE

False = False
True = True
All Records = (Null)

=IIF(IsNothing(Parameters!parmTRUEFALSE.Value), ObjectFieldName.Value, Parameters!parmTRUEFALSE.Value)

If the user selects All Records... the filter uses ObjectFieldName.Value and returns all records because @parmTRUEFALSE = (Null) / IsNothing

Upvotes: 2

Related Questions