Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
sushil353
Master II
Master II

how to store multiple row data in single coulmn

Hi all,

I have a source table in which when an error occured, related error msg is stored in multiple rows. how can i store all msgs in single row/coulmn

Please find the attached sample application.

tab1.JPG  f2.JPG

1 Solution

Accepted Solutions
derekjones
Creator III
Creator III

Hi Sushil

Use a concat in the load.

LOAD

BSN as bsn,
'Runtime_error_occured'
as error,

concat(Measure,' ') as measure

RESIDENT source_table group by BSN;

See attached amended script in your qvw,

Hope this helps.

Derek

View solution in original post

3 Replies
derekjones
Creator III
Creator III

Hi Sushil

Use a concat in the load.

LOAD

BSN as bsn,
'Runtime_error_occured'
as error,

concat(Measure,' ') as measure

RESIDENT source_table group by BSN;

See attached amended script in your qvw,

Hope this helps.

Derek

sushil353
Master II
Master II
Author

Hi Derek,

Thanks for you valuable reply,

It seems it is done correctly but in measure field error msgs are not concatenated in order.

they should be concatenated in order as given in the source table...

Please help me to sort out this issue.

Thanks

Sushil

derekjones
Creator III
Creator III

OK, possibly slightly more complicated then.

You need to add a record count to your original table so it has a numeric value of the load order, from this you can the use this 'RecordNo' to fix the order of the concatenation.

Attached is your example with the required fix, however if you are bringing in the raw data from a text file/qvd etc, it's much easier than the script I've used as you won't need to create a temp table, you can simply just add RecNo() as RecordNo to the start of your load.

Hope this helps

Derek