I am working with a dashboard control that is a multi-select dropdown with "Show unfiltered Chart Data" Enabled.
I am working with a visual query that needs to evaluate if the control is 'deselected'. Using a Custom Formula, I've been able to successfully get the following to work as expected.....
CASE WHEN {PRODUCT} != '' THEN 1 END
If I select a single Product in the control the custom formula column will correctly put a 1 on any record with the matching Product. If I select more than one single Product, then I get an error:
[SQLITE_ERROR] SQL error or missing database near (",": syntax error)
I've tried also counting the number of Products selected but couldnt figure that out either.
If i may add my experience to this chat, maybe my trial and error outcome might benefit some...
For this to work, your Dropdown control must allow Multi-selection and Show unfiltered Chart data. (i have not tried other configurations, as this setup met what I needed at the time).
ok, so i did need to find out what the count was for selected items, lol.....
LENGTH("{DROPDOWN}") - LENGTH(REPLACE("{DROPDOWN}", ',', '')) + 1
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hey @bryan_n_burrets , please try the formula below and let me know if it helps you flag records that match one of the PRODUCT dropdown selections.
CASE WHEN "Product" IN ({PRODUCT}) THEN 1 ELSE 0 END
Replace "Product" in the formula above with the column name in your chart/query.
Out of curiosity, are you looking to filter with the PRODUCT dropdown, or are you working on a scorecard that counts up how aligned records are to dropdown selections? Or something else?
I have not been able to figure out how to return a count of the number of selected items in a dropdown though, but if you can tell me how you want to use this information, I may be able to figure out a different solution.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.