title: Filter comma separated values in Tableau [ Filter Paramters with unique values ]
body: <p>My table has two columns,</p>
  
  <pre><code>X_ID                                                     Code
  
  234324_sfsdf_ADA, INT                                  ADA, INT      `
  
  343424_gdfg234_LMR                                        LMR 
  
  1233_dfgdfg_QXT                                           QXT
  
  5423_tsdg_OLI                                             OLI
  </code></pre>
  
  <p>I want to create a new filter in Tableau which has unique values of codes as [ADA, INT, LMR, QXT, OLI] and then I need to check in X_ID Column if the code appears in X_ID.</p>
  
  <p>For now, what i have done is </p>
  
  <ol>
  <li>Separated the code into two columns code1, code2</li>
  <li>I have created a parameter named "parameter1" which has all unique values from code1, code2</li>
  <li>Then I am creating a calculated field where i check </li>
  </ol>
  
  <p><code>IF CONTAINS([X_ID],[Parameter1]) THEN [Parameter1] END</code> </p>
  
  <p>The output of above step is , </p>
  
  <blockquote>
    <p>parameter1 = [ADA,INT,LMR,QXT,OLI]</p>
  </blockquote>
  
  <p>The problem here is that Parameter1 only checks for its first value. So, In my case the Parameter1 has first value as ADA. So, the condition of <code>CONTAINS([X_ID],[Parameter1])</code> is checked only for value ADA and not other values of parameter1. </p>
  
  <p>My questions are:</p>
  
  <ol>
  <li>What should be done so that for all the values of parameters the X_ID is checked. </li>
  <li>If that's not possible is there any other way to achieve this task</li>
  </ol>