Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Write Table now available in Qlik Cloud Analytics: Read Blog
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

applymap


i have ritten

map2:

mapping load * inline [
x,y
usa,us
u.s.a,us
americ,us
]
;

in expression:

=

ApplyMap

('map2','americ','not')

can any 1 tell y its not wrkng

1 Solution

Accepted Solutions
Not applicable
Author

dont write apply map in expression

u have to write in another table

View solution in original post

4 Replies
Not applicable
Author

dont write apply map in expression

u have to write in another table

Colin-Albert
Partner - Champion
Partner - Champion

Applymap is used in the load script when loading data into a table.

Applymap cannot be used in charts or front-end expressions as all mapping tables are deleted when the load finishes.

You need to use           Appymap('map2', yourdatafield, 'now') as country

Not applicable
Author

even when i do this, it is showing error:

map2:

mapping load * inline [
x,y
usa,us
u.s.a,us
americ,us
]
;
gt:
LOAD ApplyMap('map2','usa','not found') as country Resident map2;


Colin-Albert
Partner - Champion
Partner - Champion

You cannot use the mapping table (map2) as the source for the gt data, you need to load the data from a different source.

The applymap expression needs to reference a field not an explicit text value 'usa' .

gt:

LOAD ApplyMap('map2', yourfieldname,'not found') as country from anotherdatatable;