Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I need to merge some cells from differents rows from a table, is it possible?
My data looks something like the below :
Name | Firstname | Code | Valid |
---|---|---|---|
Name 1 | Firstname1 | Code1 | yes |
Name 1 | Firstname1 | Code2 | yes |
and i want as a result
Name | Firstname | Code | Valid |
---|---|---|---|
Name 1 | Firstname1 | Code1, Code2 | yes |
I was thinking about using the "concat" function, but it seems it wrong the dimension...
is there any way to do this with many lines?
Thanks
In the Dimension, you can try this
Aggr(Concat(DISTINCT Code, ', '), Name)
Concat is the right way to go...
LOAD Name,
Firstname,
Concat (Code, ', ') as Code,
Valid
FROM ....
Group By Name, Firstname, Valid;
In the Dimension, you can try this
Aggr(Concat(DISTINCT Code, ', '), Name)
This one actually worked the way I wanted to ! Thanks
Thank you @sunny_talwar great answer! Helped me out. Cheers.