I'm using the function string_agg to show together some values of the same ID, and it works well because it shows the info concatenated:
SELECT string_agg(table1.value , '#BR#') as "values"
FROM table1 WHERE id=1
id | values
--------------
1 | v1#BR#v2#BR#v3#BR#v4#BR#v5#BR#v6
Is there a way I can show the info on separated columns? Something like this:
id | values | values | values | values | values | values |
----------------------------------------------------------
1 | v1 | v2 | v3 | v4 | v5 | v6