List Filter Question

17 years 7 months ago #19833 by shack
List Filter Question was created by shack
Hello,
I have a question about the filter strings. I am trying to separate my user lists from a field that I created. So far this works fine when I only try to list only 1 group from that field.

example:
Field = cb_status, this contains: Item_1, Item_2, Item_3, Item_4

list one `cb_status` ='Item_1'
list two `cb_status` ='Item_2'

and I want list three to display Item_3 and Item_4
I have tried: `cb_status` ='Computer Services' AND `cb_status` ='Admissions' but the list comes up empty?

Anyone have any suggestions?
Thanks

Please Log in to join the conversation.

17 years 7 months ago #19837 by nant

Please Log in to join the conversation.

17 years 7 months ago #19841 by shack
Replied by shack on topic Re:List Filter Question
hmm I still am not getting it:

`cb_status` LIKE'%Item_3% LIKE %Item_4%'

What would be the correct way to do it?

Please Log in to join the conversation.

17 years 7 months ago #19851 by nant
Replied by nant on topic Re:List Filter Question
Multiselect field values are stored in the database as one string separated by a semicolon.

So, if you have a field that accepts values: item1, item2, item3, item4 and for a specific instance item1 and item3 are selected then the actual value of the field that is stored in the database if item1;item3. So if you are searching for rows that have item1 selected you should use something like:

cb_field LIKE %item1%

Experiment.

Please Log in to join the conversation.

17 years 7 months ago #19888 by shack
Replied by shack on topic Re:List Filter Question
Thank you for your help. I was able to get it to work:

`cb_status` ='item1' OR `cb_status` =item4' OR`cb_status` ='item6'

On one of the lists I had to increase the filterfields size in the database because it was cutting off my really long string.

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.168 seconds

Facebook Twitter LinkedIn