I'm looking to have a Saved Search formula that wo...
# suiteanalytics
e
I'm looking to have a Saved Search formula that would result in a Color being shown if it is part of an item description - possible to do something like: CASE WHEN {item.description} contains (not sure the sql equivalent for contains is) ("blue", "red", "yellow") THEN show the color that the description contains END
b
Im generally bad at formulas, so I say brute force it
CASE WHEN INSTR({item.description}, 'blue') > 0 THEN 'blue' WHEN INSTR({item.description}, 'red') > 0 THEN 'red' WHEN INSTR({item.description}, 'yellow') > 0 THEN 'yellow' END
hopefully your descriptions don't contain multiple colors
s
Do you want to display the color name, or actually style the search results based on the color? If it's the latter, I saw this article once, though never had the need for it myself: http://www.melioza.com/2016/08/common-html-code-to-format-netsuite.html The basic idea is wrapping the column in a DIV or SPAN tag so you can apply styles to it.
e
Thanks for your help guys!