7 Replies Latest reply on Nov 27, 2017 12:49 PM by Shinichiro Murakami

    Comparing Text Strings in Tableau

    Meghan Garman

      Hi there!


      I need a way to compare text string fields and create a calculated field that contains the characters that only occur in one of the fields.  The order of the characters is not the same every time.  For example, in one string I may have 6100,6202,6600 and in the other I have 6000,6100,6101,6102,6202,6600,6700,6702.  How do I create a calculated field that returns "6000,6101,6102,6700,6701" -- the characters/strings that are the difference between the two?


      I have tried using the replace function but that only works if the strings are in the same order, which is not necessarily the case.


      I am using Tableau Desktop version 10.1. 


      Any suggestions would be a huge help!  Thank you!