Quantcast
Channel: SCN : Discussion List - SAP HANA and In-Memory Computing
Viewing all articles
Browse latest Browse all 5653

Select a comma delimited list from table column

$
0
0

Hi,

 

I have a table with two columns. CustomerID and AccountManager.

 

Most customers have just one account manager. Some have two or more.

 

I need to query the table, returning one row per CustomerID, with the AccountManager. For the customers with more than one account manager, I need to return a comma separated list of account managers.

 

e.g.

Customer table:

table.png

 

Query result:

query_result.png

I need the query result as a view for further use.

 

Can anyone give me a tip, without using a Cursor?

 

Thanks in advance,

Rob


Viewing all articles
Browse latest Browse all 5653

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>