title: SQL Server table result to array in SQL Server 2005
body: <p>Hi and thanks in advance.</p>
  
  <p>First off, I do not mean I want to convert an array into a table. I can do that. Easy :)</p>
  
  <p>I would like to do the opposite.</p>
  
  <p>I have a row with <em>n</em> rows related to it in another table. I wish to output the row and then within a single column of that row, let's say <code>Children</code>, its linked rows in an <strong>array</strong> (or a string that I can interpret as an array with front-end code).</p>
  
  <p>Like this:</p>
  
  <pre><code>ID   TITLE   DESCRIPTION   CHILDREN
  --------------------------------------------------------
  36   Blah    Blah Blah     ['Bob','Gary','Reginald']
  20   Pah     Pah Pah       ['Emily','Dave']
  </code></pre>
  
  <p>You see?</p>
  
  <p>I know, this is probably not the best way to do it. But, it's for a specific use that would be too long to explain here.</p>
  
  <p>Thanks again.</p>