0

I have a simple query that does group concat very well in SQL workbench.

id hobby
 1 dance
 1 sing
 2 play
 2 sing

Expected output:

id hobby
1 dance,sing
2 play,sing

How can I get this output using MS SQL Server?

2
  • 2
    Starting from MS Sql Server 2017 you have STRING_AGG Commented Feb 26, 2019 at 22:32
  • Yes, my version is SQL 2012 Commented Feb 26, 2019 at 23:12

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.