on 06-03-2014 5:25 PM
Not sure if this is the correct wording, but my report was reading from a view {Drivemaster.OpenToPublic} and the only possible values in the column are 0/1 for True/False.
I initially set this report up with a formula to process the parameter:
if {?OpenToPublic} = 'Yes' then {rpt_DriveMaster.OpenToPublic}
else {rpt_DriveMaster.OpenToPublic} = False
And then to display the selected value in the report as:
if {rpt_DriveMaster.OpenToPublic} then 'Yes'
else 'No'
But now they would like to have the parameter modified to select Yes/No/Both so I believe I need to modify the top formula to read:
if {?OpenToPublic} = 'Yes' then {rpt_DriveMaster.OpenToPublic} = True
else if {?OpenToPublic} = 'No' then {rpt_DriveMaster.OpenToPublic} = False
Hopefully this would return all values if Yes/No are not selected.
But I'm not sure if this is correct and then I am not entirely sure how to change the bottom formula to have the selected columns display "All" instead of Yes or No for "Open to the Public"
Suggestions?
Hi Trey,
Make that parameter to Optional prompt, to make optional prompt in the paremeter you need to change the properties of parameter as Optional prompt as "true".
with the optional prompt if you specify 'yes' it will display those vales, if 'NO' it will display those values, if you didn't specify any values then it will display all values.
the formula is look like the below
if (HasValue({?OpenToPublic}) = "Both" then true
else if {?OpenToPublic} = 'Yes' then {rpt_DriveMaster.OpenToPublic} = True
else if {?OpenToPublic} = 'No' then {rpt_DriveMaster.OpenToPublic} = False
Hope the above information will help you.
--Naga.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks Naga,
I wasn't able to get your formula to work, but I added an additional else to my formula and it appears to be working correctly:
if {?OpenToPublic} = 'Yes' then {rpt_DriveMaster.OpenToPublic} = True
else if {?OpenToPublic} = 'No' then {rpt_DriveMaster.OpenToPublic} = False
else {rpt_DriveMaster.OpenToPublic} = {rpt_DriveMaster.OpenToPublic}
User | Count |
---|---|
86 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.