Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hey guys, I have this .txt file that is a bit different the extraction for qlikview to read it as a database. In order to become a database, I managed this by using the fill out in the transformation step, but i wonder if there is a better way of doing it, easier one...
Please, check it out the .txt file, try to load it in the qlikview, and tell me if there is a better way than using the fill out step.
Thank you,
Depending on what you want to wind up with, one approach may be:
Raw:
LOAD @1,
@2,
@3,
@4
FROM
[My restaurant.txt]
(txt, codepage is 1252, no labels, delimiter is '\t', msq, header is 0 lines, filters(
Replace(1, top, StrCnd(null))
));
Menu:
LOAD
if(@2='',peek('Course', RowNo()-2), @2) as Course,
if(@3='',peek('Dish', RowNo()-2), @3) as Dish,
@4 as Ingredient
RESIDENT Raw
WHERE @1 = 'Menu'
;
And then do the same for Foods and Ingredients as I did for menu.
-Rob
Hi Julio,
Please see the attachment.
Thanks,
AS
You can use Generic Load pfa sample.
vikas
Depending on what you want to wind up with, one approach may be:
Raw:
LOAD @1,
@2,
@3,
@4
FROM
[My restaurant.txt]
(txt, codepage is 1252, no labels, delimiter is '\t', msq, header is 0 lines, filters(
Replace(1, top, StrCnd(null))
));
Menu:
LOAD
if(@2='',peek('Course', RowNo()-2), @2) as Course,
if(@3='',peek('Dish', RowNo()-2), @3) as Dish,
@4 as Ingredient
RESIDENT Raw
WHERE @1 = 'Menu'
;
And then do the same for Foods and Ingredients as I did for menu.
-Rob