[solved] Question on Conditionals: FIND_IN_SET()
When displaying a list module, you can enter a conditional to filter out items. I've used it successfully against a select field, however I'm having trouble with a tag field and multiple selections.
The situation is this: I have a tag field that points to a specific section of the Taxonomy tree. The selections I can choose are Professional, Consumer, and Accessory. These are 34, 35, and 36 if your looking at the Tag ID. Since an Item can be both a Professional AND Consumer Item, I needed to be able to select both, thus the use of Tags.
Now, I have a list module on my Consumer page with a Conditional.
This will show anything tagged with Consumer just fine.
Now, on my Professional Page,
This will show any item tagged ONLY as professional, but NOT items tagged both Consumer AND Professional.
The question is, how would I word the conditional so that it would show the items tagged with multiple classes?
Re: Question on Conditionals
There is an example in the forums and tutorials, you have to use FIND_IN_SET(field, '35,34')>0
Re: Question on Conditionals
Ahh, thank you.
Code:
FIND_IN_SET(35,product_class)>0
this ended being the query that did the trick.