title: Freemarker: Output comma separated list as an array
body: <p>I have a table that has a field that contains a comma separated list of order IDs. What I am trying to do is output each of those IDs separately so that I can use them to look up their corresponding order details in another table. </p>
  
  <p>Does anyone know of a good way to do this?</p>
  
  <p>So far I have tried:</p>
  
  <pre><code>    &lt;#data Alerts_test_table as alerts_test&gt;
      &lt;#filter
      CUSTOMER_ID_=CONTACTS_LIST.CUSTOMER_ID_1&gt;
      &lt;#fields AD_ID_LIST&gt;
  
      &lt;#assign seq = ['${alerts_test.AD_ID_LIST}']&gt;
      &lt;#list seq?chunk(1) as row&gt;&lt;#list row as cell&gt;
      ${cell}
      &lt;/#list&gt; &lt;/#list&gt;
  
      &lt;/#data&gt;
  </code></pre>
  
  <p>But this just outputs it as a line of text. </p>