title: How to replace STRING_AGG and CONCAT in MS SQL Server 2008?
body: <p>I use MS SQL Server 2008 and this server version doesn't support some helpful functions like <code>CONCAT</code> and <code>STRING_AGG</code>, but they are really needful in my work.
  What variants can I have for replacing those functions in MS SQL Server 2008?</p>
  <p><strong>IMPORTANT!</strong> I have no possibility to update Server to newer version.</p>
  <p>Code for better understanding:</p>
  <pre><code>SELECT Pt.ImagePath, STRING_AGG(Pt.DamageData, '') DamageData 
  FROM @PreTable AS Pt 
  GROUP BY ImagePath 
  ORDER BY DamageData
  </code></pre>