Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello Grus,
I have the location master table in my database which is like
locID | location |
---|---|
1 | abc |
2 | xyz |
3 | ghi |
4 | stu |
now i have a transaction table with the field
transaactionID | locID | DeliveryPlaceCode | WorkingPlaceCode | amount |
---|---|---|---|---|
123465a | 1 | 2 | 4 | 5000 |
123456b | 2 | 2 | 3 | 6000 |
note: the value in locId, DeliveryPlaceCode and WorkingPlaceCode are refer to location master table
now i i fetch this table in to qlikview
location:
load
locID,
Location
from location.qvd;
Transaction:
load
Transaction Id,
locId,
DeliveryPlaceCode ,
WorkingPlaceCode
from xyz.qvd
link will be created between the two table with locId and I can easily find out the locationname against each locId
now,
how can I find out the location name for deliverycode and workinplacecode;
plz help
As Mindaugas said, it would be better to use Mapping Load, here is how the script would look like
MappingTable:
Mapping
LOAD locID,
location
FROM
[https://community.qlik.com/thread/215298]
(html, codepage is 1252, embedded labels, table is @1);
LOAD transaactionID,
locID,
ApplyMap('MappingTable', locID) as Location_locID,
DeliveryPlaceCode,
ApplyMap('MappingTable', DeliveryPlaceCode) as Location_DeliveryPlaceCode,
WorkingPlaceCode,
ApplyMap('MappingTable', WorkingPlaceCode) as Location_WorkingPlaceCode,
amount
FROM
[https://community.qlik.com/thread/215298]
(html, codepage is 1252, embedded labels, table is @2);
While connecting location master table with transaction table use Mapping:
Mapping as an Alternative to Joining
Regarding DeliveryPlaceCode and WorkingPlaceCode your database should have the familiar master tables like Location master table.
As Mindaugas said, it would be better to use Mapping Load, here is how the script would look like
MappingTable:
Mapping
LOAD locID,
location
FROM
[https://community.qlik.com/thread/215298]
(html, codepage is 1252, embedded labels, table is @1);
LOAD transaactionID,
locID,
ApplyMap('MappingTable', locID) as Location_locID,
DeliveryPlaceCode,
ApplyMap('MappingTable', DeliveryPlaceCode) as Location_DeliveryPlaceCode,
WorkingPlaceCode,
ApplyMap('MappingTable', WorkingPlaceCode) as Location_WorkingPlaceCode,
amount
FROM
[https://community.qlik.com/thread/215298]
(html, codepage is 1252, embedded labels, table is @2);
thanks alot dear