Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

ApplyMap with LOAD INLINE not working

Hi folks,

Usually I don't struggle with the ApplyMap function, has been working great.  However, when I try to use it with an INLINE lookup such as the example below, it will not map to AAContactNoDesc.  Am I doing something wrong here?

MAP_AACONTACTNO:

MAPPING LOAD * INLINE

[AAContactNumber, AAContactNoDesc

'0113 438 0120','Flying to Mars'

'0330 780 7436','Flying to the Moon'];

LOAD Letter_code,  

     DELIVERY_NNA,  

     ApplyMap('MAP_AACONTACTNO',AAContactNumber) as AAContactNoDesc,  

     LoadedDate

FROM [\\abcdef.qvd] (qvd);

Many thanks, Alex

31 Replies
Not applicable
Author

Thanks Peter.

Not applicable
Author

And for those that have been following this post, it seems that the key function that really made a difference was KeepChar.  The data loading into AAContactNumber was formatted like 0800 123 1234, however, the spaces between the numbers were not being seen by QV as spaces.  Therefore, KeepChar filters out all non-numerics to leave a clean text string that could be mapped to a description.

MapSubString('MAP_AACONTACTNO2',text(keepchar(AAContactNumber,'0123456789'))) as AAContactNoDesc,


For reference, I was obviously just assuming that what appeared to be spaces were spaces and treated as spaces .

Thanks to KeepChar, I can now successfully map millions of calls to a description.