Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
ychaitanya
Creator III
Creator III

Please Help

Mapping Load * INLINE [ Role,Description

SSE,'Senior Software Engineer'

SEA,'System Enterprise Analyst',

JSE,'Junior System Engineer',

ASOC,'Associate',

Trainee,'Associate Trainee',

ITT,'IT Technical',

DSA,'Design Systems Analyst']


;

I Have loaded Map_Table and i want to look up from field called Designation in Employee Table  to Description in Map_Table using the Deisgnation and Role.

I could see below code is loading fine but not fetching the output.

Please check and help on the same.

Load Designation,

Lookup('Description',Designation,'Role','Map_Table') as Long_Desc

FROM Employee.xlsx

(
ooxml, embedded labels, table is Sheet1);

1 Solution

Accepted Solutions
MK_QSL
MVP
MVP

ApplyMap is much faster than Lookup but if you want to test it, below is the code...

Temp:

Load * INLINE

[

  Role,Description

  SSE,'Senior Software Engineer'

  SEA,'System Enterprise Analyst'

  JSE,'Junior System Engineer'

  ASOC,'Associate'

  Trainee,'Associate Trainee'

  ITT,'IT Technical'

  DSA,'Design Systems Analyst'

];

Employee:

Load *, Lookup('Description','Role',Designation,'Temp') as Long_Desc Inline

[

  Designation, Salary

  SSE, 100

  JSE, 200

  ITT, 300

  MMM, 200

];

Drop Table Temp;

But I would suggest to do below instead of Lookup...Though Mapping Load and ApplyMap is my obvious choice...

Left Join (Employee) Load Role as Designation, Description as Long_Desc Resident Temp;

Drop Table Temp;

View solution in original post

7 Replies
MK_QSL
MVP
MVP

Instead of LookUp use as below

ApplyMap('Map_Table',Designation,'UNKNOWN') as Long_Desc

ychaitanya
Creator III
Creator III
Author

I have tried working with Mapping_load it works, but i want to know how to make using Lookup?

maleksafa
Specialist
Specialist

when using mapping load , you should use the applyMap with it and not the lookup function.

ychaitanya
Creator III
Creator III
Author

I have just tried normal inline load as

But Not working..

Load * INLINE [ Roles,Descriptions

SSE,'Senior Software Engineer'

SEA,'System Enterprise Analyst',

JSE,'Junior System Engineer',

ASOC,'Associate',

Trainee,'Associate Trainee',

ITT,'IT Technical',

DSA,'Design Systems Analyst']


;



Lkp_Table:

Load Designation,

Lookup('Descriptions',Designation,'Roles','Lkp_Base') as Long_Desc

FROM Employee.xlsx

(
ooxml, embedded labels, table is Sheet1);

Not applicable

Hi

Could you not use a simple left join based on description?

That might work

MK_QSL
MVP
MVP

ApplyMap is much faster than Lookup but if you want to test it, below is the code...

Temp:

Load * INLINE

[

  Role,Description

  SSE,'Senior Software Engineer'

  SEA,'System Enterprise Analyst'

  JSE,'Junior System Engineer'

  ASOC,'Associate'

  Trainee,'Associate Trainee'

  ITT,'IT Technical'

  DSA,'Design Systems Analyst'

];

Employee:

Load *, Lookup('Description','Role',Designation,'Temp') as Long_Desc Inline

[

  Designation, Salary

  SSE, 100

  JSE, 200

  ITT, 300

  MMM, 200

];

Drop Table Temp;

But I would suggest to do below instead of Lookup...Though Mapping Load and ApplyMap is my obvious choice...

Left Join (Employee) Load Role as Designation, Description as Long_Desc Resident Temp;

Drop Table Temp;

ngulliver
Partner - Specialist III
Partner - Specialist III

Hi, Chaitanya.

I notice in your inline load you are putting commas at the end of each line. I don't think this is required.

e.g. SEA,'System Enterprise Analyst'

not SEA,'System Enterprise Analyst',

Regards,

Neil