Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
trishita
Creator III
Creator III

How can I map these two tables using mapping function and apply map with conditional expressionbetween 2 tables

 

I need to map two fuel types FIELD from 2 tables, Sounding correction and Summary depending on the sulphur content of the sounding correction table.How can I map these two tables using mapping function and apply map with conditional expression

   

Sounding Correction.Fuel TypeSounding Correction.Sulphur ContentSummary.Fuel Type
DMA<.01LSDO
DMB<.01LSDO
DMC<.01LSDO
DMA>.01HSDO
DMB>.01HSDO
DMC>.01HSDO
RMA<.01ULSFO
RMG<.01ULSFO
RMD<.01ULSFO
RMA>.01HSFO
RMG>.01HSFO
RMD>.01HSFO

If (Sounding Correction.Fuel Type = ‘DM*’) and (Sounding Correction.Sulphur Content)

 

Greater than  0.1 , Summary.Fuel Type = ‘HSDO’

 

  Or else ‘LSDO’

     

If (Sounding Correction.Fuel Type = ‘RM*****’) and (Sounding Correction.Sulphur Content)

 

Greater than  0.1 then (Summary.Fuel Type) = ‘HSFO’

   

Or else ‘ULSFO’

 

16 Replies
olivierrobin
Specialist III
Specialist III

map1:

mapping load

key,value

from ......

where key is the value you are looking for

and value will be the returned value

have a look in QV documention at

8 Introduction to loading data

Using a mapping table

trishita
Creator III
Creator III
Author

because I am trying to connect two tables..these tables have been joined already previously but I was getting redundant data...

shiveshsingh
Master
Master

So why not using the expression, you'll get the desired result.

Please try it once

trishita
Creator III
Creator III
Author

I am not getting the expression even if I am using it because I want to see values against rmk 700 which is HSFO but its not reflected..if I can map rmk with the exact code then I think the redundant data can be avoided:

if(WildMatch(FUEL_TYPE, 'DM*') and [SULPHUR_CONTENT] = '.1','HSDO',

if(WildMatch(FUEL_TYPE, 'DM*') and [SULPHUR_CONTENT] <> '>.1','LSDO',

if(WildMatch(FUEL_TYPE,'RM****') and [SULPHUR_CONTENT] = '>.1', 'HSFO','ULSFO')))

Result is erroneous: You can see only the highlighted row is the required data..but I have several rows of redundant data...and also it is not ULSFO

shiveshsingh
Master
Master

ok, so if it's RMK 700 , then you need HSFO in resultant column?

trishita
Creator III
Creator III
Author

RMK 700 if has sulphur content less than .1 will be ULSFO or HSFO.But as the the two columns are not mapped properly u can see there are redundant data...all the columns are showing duplicate data...which is not correct...only rmk 700 which has hsfo has the correct data which is -42.

u can see the other fields are showing redundan data, apart from this highlighted field no other values should come

shiveshsingh
Master
Master

Hi

What are your dimensions?