Solved

SSRS - Clearing a multi-select drop down

Posted on 2014-10-26
3
349 Views
Last Modified: 2014-10-27
I have two drop downs on my report.  One is single select and the other is multi select.  If I go in and select multiple values from the multi select drop down and run the report then it pulls back the data fine.  Now if I change the value in the single select drop down it refreshes the multi-select drop down with only appropriate values, but the values that I checked before are still checked.    

Is there anyway I can clear all the previous selections in the multi-valued drop down.
0
Comment
Question by:sherbug1015
3 Comments
 
LVL 14

Expert Comment

by:Vikas Garg
ID: 40405835
Hi,

I think that the parameters are Cascading Parameter due to which value of the list changes when value changes in the other parameter.

Hope the below link will give you idea of the cascading parameter

http://technet.microsoft.com/en-us/library/aa337498%28v=sql.105%29.aspx
0
 
LVL 22

Accepted Solution

by:
Nico Bontenbal earned 500 total points
ID: 40405863
I never noticed this before but after some research I think the behavior is even stranger then you describe it. I've create a report with a singe select that shows the values between 1 and 10. And a multi select that shows the values between 2 less and 2 more than the value selected in the single select. So when I select 4 in the single I get the values 2-6 n the multi. When I then select 3 and 4 in the multi and then select 5 in the single, the 3 and 4 are still selected in the multi. But when I select 6 in the single all the values in the multi are cleared. So it looks like the values in the multi are only kept if all them are available. If one is not available the entire selection is reset.
See the sample report MultiSelect1. You'll need to change the Data Source for this report to work. Just point it to any SQL Server database.

I'm afraid there is no easy way to fix this. You just have to make sure that when you select another value in the single select all the values of the multi select are different. I've done this by using this query for the multi select:
SELECT (@single*1000000)+ Number as Number, Text FROM ...

Open in new window

So I add the value of the single select multiplied by 1000000 to the number of the multi select. This only works if the Number for the multi select is always below 1000000 of course. You might need to use a larger value.

This will break your select statement in the data query of course. You'll have to change that one too:
where (@single*1000000)+ Number in (@multi)

Open in new window

See the report MultiSelect2 for a working example.
MultiSelect1.rdl
MultiSelect2.rdl
0
 

Author Closing Comment

by:sherbug1015
ID: 40406179
Thanks.  Not that I know what is causing it, I can provide some workaround.  Thanks again.
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Suggested Solutions

In this article I will describe the Backup & Restore method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

759 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now