Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
hi,
is it possible to use a field from another (allready loaded) table in a load condition of another table ?
its possible in sql, but how could it be done in qlikview script ?
the table "customers" is loaded first.
"customers" (customer_id, customer_area, subarea_code, customer_name)
customer_area= city
subarea_code= district/zipcode
f.e. i want to load purchase histories from one table
"sales" (order_id, order_date, order_amount, item_ID, customer_id)
BUT only for customers who live in a certain area
of course this could be done in the document with listboxes etc. But the huge amount of data from orders should be limited during load.
i could be usefull for other loads too, especiall with large amounts of data and distributed dependencies.
Hi,
so you load a mastertable > customers < first?
You could do a restricted RESIDENT LOAD of that, restricting to the areas that you want (if you don't want all of them) and then use a WHERE EXISTS clause in the following LOAD of the > sales < table?
HTH
Hi,
so you load a mastertable > customers < first?
You could do a restricted RESIDENT LOAD of that, restricting to the areas that you want (if you don't want all of them) and then use a WHERE EXISTS clause in the following LOAD of the > sales < table?
HTH
yes, >customers< is loaded before >sales< . i edited the question to make that more clear.
your proposal worked well, thank you.
the load of the >customers< list will be restricted by area, containing only users that match the area.
other users needed to be loaded later on, f.e. with outer join load.the
i only used where not exists before for incremental loads
where NOT exists (change_date)
WHERE EXISTS (subarea_code) worked fine.