title: Google Sheets Formula to create a 1-column unique output range of all unique values in range of "jagged list"
body: <p>Document: <a href="https://docs.google.com/spreadsheets/d/1N4cGw5eUq_3gCJh1w39qVatX9KV1_Hr-AqRHj_nbckA/edit?usp=sharing" rel="nofollow noreferrer">https://docs.google.com/spreadsheets/d/1N4cGw5eUq_3gCJh1w39qVatX9KV1_Hr-AqRHj_nbckA/edit?usp=sharing</a></p>
  
  <hr>
  
  <h2>Data Expectation</h2>
  
  <p>At <code>Current Class!H3</code>, the table data is the data that is presented in the dropdown menu. </p>
  
  <p>This data comes directly from <code>Meta!B7:B</code> ...</p>
  
  <p>...which can come from one of the columns from <code>Students!$J$5:$O</code>. The column is determined by the value in <code>Current Class!B3</code></p>
  
  <pre><code>      Current               Expected  | Example Data        Expect
     ---------------          --------  | ------------        ------
  1) M1, M2, M3, M4             M1      |  1) M1, M2   ---&gt;   M1
  2) M2                         M2      |                     M2
  3) M3                 ---&gt;    M3      | --------------------------
  4) M4                         M4      |  1) T4              M2
  5) M5                         M5      |  2) M2       ---&gt;   T4
  6) M4, M5, M6                 M6      |  3) TH3             TH3
  </code></pre>
  
  <p>As you might be able to determine, I have a possible list of items in a single row (This indicates that 1 student has multiple classes in one specific room - this case the <code>Yale</code> classroom).</p>
  
  <p><strong>What I want is to separate the lists into individual items and to produce a 1-column output range of only unique values.</strong></p>
  
  <p><em>I have tried to use the <code>SPLIT()</code> function. While that breaks apart each item but I cannot find a solution to flatten the results to 1 column only.</em> But right now I have the following formula in <code>Meta!B7</code> ...</p>
  
  <pre><code>=iferror(Sort(Unique(Filter(Students!$J$5:$O, Find($B$6, Students!$J$4:$O$4) &gt; 0 )), 1, true), "")
  .
  </code></pre>