
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Mapping load with multiple values
Hi qlikss,
I have mapping table with multiple values.
Mapping table:
Key. Mail
100. Sri@gmail.com
100. 999-6667-778
100. 6785-889-888
200. 998- 5466-766
200. John@gmail.com
Applyma p(table,key)
How can I get only mail IDs in applymap when multiple values are there in mapping table
- Tags:
- qliksense app
Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@stonecold111 you can always use script like :
DataMap:
load * inline [
Key,Mail
5,sdsdsdsd@ss
100,Sri@gmail.com
100,999-6667-778
100,6785-889-888
200,998- 5466-766
200,John@gmail.com
]; left join load Key,count(Mail) as counttmp resident DataMap group by Key;
TmpMap:
load Key,Mail resident DataMap where counttmp>1 and WildMatch(Mail,'*@*')>0;
load Key,Mail resident DataMap where counttmp=1;
drop table DataMap;
Map1:
mapping load * resident TmpMap;
drop table TmpMap;
Data:
load Key1, applymap('Map1',Key1,'ND') as Mail inline [
Key1
100
200
5
];
output:
Taoufiq ZARRA
"Please LIKE posts and "Accept as Solution" if the provided solution is helpful "
(you can mark up to 3 "solutions") 😉

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Mail is at different occurances . sometimes it's at first, sometims 2nd or 3rd position.
@

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@stonecold111 you can always use script like :
DataMap:
load * inline [
Key,Mail
5,sdsdsdsd@ss
100,Sri@gmail.com
100,999-6667-778
100,6785-889-888
200,998- 5466-766
200,John@gmail.com
]; left join load Key,count(Mail) as counttmp resident DataMap group by Key;
TmpMap:
load Key,Mail resident DataMap where counttmp>1 and WildMatch(Mail,'*@*')>0;
load Key,Mail resident DataMap where counttmp=1;
drop table DataMap;
Map1:
mapping load * resident TmpMap;
drop table TmpMap;
Data:
load Key1, applymap('Map1',Key1,'ND') as Mail inline [
Key1
100
200
5
];
output:
Taoufiq ZARRA
"Please LIKE posts and "Accept as Solution" if the provided solution is helpful "
(you can mark up to 3 "solutions") 😉

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Just by taking resident load with where condition
As wildmatch(mail,*@*) loads only records that has @ ,then we can join or use applymap.
Do we really need all these count function etc..

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
if you you have alway one row with @ you don't need all these count
Taoufiq ZARRA
"Please LIKE posts and "Accept as Solution" if the provided solution is helpful "
(you can mark up to 3 "solutions") 😉

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Ok thanks
