Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
my source data contains a table with just two fields:
Sales | Products |
---|---|
John | Food, Goods, Electronic |
Jack | Food, Drinks, Games, Cars |
From this format i would like to create a table like:
Sales | Product |
---|---|
John | Food |
John | Goods |
John | Electronic |
Jack | Food |
Jack | Drinks |
Jack | Games |
Jack | Cars |
Some help of how i can loop through the field and extract value by value would be much appreciated!
thanks,
P
Use the subfield() function
Load
Sales
subfield(Products, ',') as Product
from ....
Use the subfield() function
Load
Sales
subfield(Products, ',') as Product
from ....
Hi,
Try like this
LOAD Sales,
Products,
trim(subfield(Products, ',')) as NewProduct
FROM
[http://community.qlik.com/thread/142160]
(html, codepage is 1256, embedded labels, table is @1);
Regards
ASHFAQ