Get certified for free when you join Fabric Data Days 2026 and dive into Fabric, Power BI, SQL, AI, and other essential data skills.
Join nowJuly 28 - August 9 | Final Round of the Power BI Dataviz World Championships. This is your chance. Learn more
hi All,
I need SQL code for below issue
I have two table as shown below
| Id | Name |
| 1 | Roy |
| 1 | Roy |
| 1 | Roy |
| 1 | Roy |
| 1 | Roy |
| Name | Type |
| Roy | GE |
| Roy | RA |
| Roy | SA |
| Roy | PA |
| Roy | PA |
These two have primary key as Name.
Desired Output
| Id | Type |
| 1 | GE,RA,SA,PA |
kindly need help
Solved! Go to Solution.
@Anonymous,
Use String_Agg if you use T-SQL: https://docs.microsoft.com/en-us/sql/t-sql/functions/string-agg-transact-sql?view=sql-server-ver15
@Anonymous
A dedicated forum might be more appropriate. In DAX, you may use CONCATENATEX to add a measure.
https://community.powerbi.com/t5/Desktop/split-by-delimiter/td-p/363277
@Anonymous
A dedicated forum might be more appropriate. In DAX, you may use CONCATENATEX to add a measure.
https://community.powerbi.com/t5/Desktop/split-by-delimiter/td-p/363277
@Anonymous,
Use String_Agg if you use T-SQL: https://docs.microsoft.com/en-us/sql/t-sql/functions/string-agg-transact-sql?view=sql-server-ver15
Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.
If you love stickers, then you will definitely want to check out our community sticker challenge, Barcelona edition!
Check out the July 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 31 | |
| 28 | |
| 24 | |
| 24 | |
| 19 |
| User | Count |
|---|---|
| 44 | |
| 32 | |
| 18 | |
| 17 | |
| 16 |