Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello everyone, how to write a script to turn T1 into T2. thanks.
t1:
monly | values |
201701 | AA |
201702 | BB,CC |
t2:
monly | values |
201701 | AA |
201702 | BB |
201702 | CC |
Try
load
monly,
subfield(values,',') as values
resident t1;
good, thank you!
Hi guiqiang,
For splitting the values in Qlik we have 'Subfield' function.
Subfield format:
Subfield (text, delimiter, field_no)
or
Subfield (FieldName, delimiter, field_no),
Now Let's talk about your table.
Subfield(Values,',',1) as Values
It is better to define field_no in the third parameter.
I have also attached example app. Hopefully, this will solve your problem.
I see, thank you very much.
Please mark as correct if you reach your solution.
Thanks.