Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Chanty4u
MVP
MVP

RE:Rows to Data

Hi all,

i have data like below  in Database file

INPUT:

Employee Table:

ExmName   EmpId     Location

AA       101          BANGLORE

AA       101          MUMBAI

AA        101         CHENNAI

BB    102     BANGLORE

CC    103    CHENNAI

CC    103    HYD 

DESIRED OUTPUT:

ExmName   EmpId     Location

AA       101          BANGLORE,MUMBAI,CHENNAI

BB     102     BANGLORE

CC    103      CHENNAI,HYD

how can i achieve this?

1 Solution

Accepted Solutions
Gysbert_Wassenaar

Create a straight table with ExmName and EmpId as dimensions and as expression concat(Location, ',')

Or if you want to do it in the script:

Result:

LOAD ExmName, EmpId, concat(Location, ',') as Locations

RESIDENT INPUT

GROUP BY ExmName, EmpId;


talk is cheap, supply exceeds demand

View solution in original post

2 Replies
Gysbert_Wassenaar

Create a straight table with ExmName and EmpId as dimensions and as expression concat(Location, ',')

Or if you want to do it in the script:

Result:

LOAD ExmName, EmpId, concat(Location, ',') as Locations

RESIDENT INPUT

GROUP BY ExmName, EmpId;


talk is cheap, supply exceeds demand
Chanty4u
MVP
MVP
Author

Thanks .It works as expected