3 Replies Latest reply on Feb 6, 2019 5:18 AM by Jim Dehner

    Search for string, but exclude some results

    katrina.johnson.2

      Is it possible to search for a certain text but exclude some results?

       

      I have a column called "PRODUCT_TAGS" where the color of an item is added as a tag (instead of a field/attribute).  The process has been to add a tag for the item's color AND add tags for the other available colors.

       

      For example, an item is titled "Black Jacket" and tagged with "Black, Series-Black, Series-Blue, Series-Charcoal".  This means this specific SKU is for a black jacket but it's also available in Blue and Charcoal.

       

      Unfortunately, they haven't been consistent in using the color in the title, so some items are titled "Jacket-M" or "Jacket-Small" so I can't use the title.

       

      Is there any way to say something like If (contains(product_tags,'black') but not 'Series-black" then "Color is black"?

       

      I've tried using some REGEX (Utilizing REGEX in Tableau — Tableauza! ) but the color tag isn't always in the same location.

       

       

      Thanks in advance for your help!