<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Applymap does not return the correct field value in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Applymap-does-not-return-the-correct-field-value/m-p/1687199#M52347</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I can see one syntax error in the ApplyMap&amp;nbsp;&lt;BR /&gt;applymap('FXFO',iF(left&lt;FONT color="#FFCC00"&gt;&lt;STRONG&gt;("acct1)&lt;/STRONG&gt;&lt;/FONT&gt;='1','A', if(left("acct",1)='2','L','na')) &amp;amp;'-'&amp;amp; "Dealno"))&lt;/P&gt;&lt;P&gt;Pl check.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 24 Mar 2020 07:37:53 GMT</pubDate>
    <dc:creator>ashishkalia</dc:creator>
    <dc:date>2020-03-24T07:37:53Z</dc:date>
    <item>
      <title>Applymap does not return the correct field value</title>
      <link>https://community.qlik.com/t5/App-Development/Applymap-does-not-return-the-correct-field-value/m-p/1687186#M52345</link>
      <description>&lt;P&gt;I have below applymap code that I want to return the 2nd field "FXFO".&amp;nbsp; But the result return the first field in of the mapping table.&amp;nbsp; May I know what I have done wrong?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;[FXFO]:
Mapping
LOAD
	"Asset/Liab Indicator" &amp;amp; '-' &amp;amp; "Trade ID" as  AL_deal#, 
    "Type We Pay/Receive" as FXFO
  
FROM [lib://test/CAO_MPMSWBTP_HK_20191231_141815.xlsm]
(ooxml, embedded labels, table is CAO_MPMSWBTP_HK_20191231_141815);

[Table]
LOAD
 iF(left("acct",1)='1','A', if(left("acct",1)='2','L','na')) &amp;amp;'-'&amp;amp; "Dealno)" as AL_deal#, 
 
applymap('FXFO',iF(left("acct1)='1','A', if(left("acct",1)='2','L','na')) &amp;amp;'-'&amp;amp; "Dealno") as FXFO,
  
FROM [lib://test/SAL LY.csv]
(txt, codepage is 28591, embedded labels, delimiter is ',', msq);
&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 20 Dec 2021 21:32:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Applymap-does-not-return-the-correct-field-value/m-p/1687186#M52345</guid>
      <dc:creator>43918084</dc:creator>
      <dc:date>2021-12-20T21:32:42Z</dc:date>
    </item>
    <item>
      <title>Re: Applymap does not return the correct field value</title>
      <link>https://community.qlik.com/t5/App-Development/Applymap-does-not-return-the-correct-field-value/m-p/1687199#M52347</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I can see one syntax error in the ApplyMap&amp;nbsp;&lt;BR /&gt;applymap('FXFO',iF(left&lt;FONT color="#FFCC00"&gt;&lt;STRONG&gt;("acct1)&lt;/STRONG&gt;&lt;/FONT&gt;='1','A', if(left("acct",1)='2','L','na')) &amp;amp;'-'&amp;amp; "Dealno"))&lt;/P&gt;&lt;P&gt;Pl check.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2020 07:37:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Applymap-does-not-return-the-correct-field-value/m-p/1687199#M52347</guid>
      <dc:creator>ashishkalia</dc:creator>
      <dc:date>2020-03-24T07:37:53Z</dc:date>
    </item>
    <item>
      <title>Re: Applymap does not return the correct field value</title>
      <link>https://community.qlik.com/t5/App-Development/Applymap-does-not-return-the-correct-field-value/m-p/1687331#M52367</link>
      <description>&lt;P&gt;I apologize it is my typo.&amp;nbsp; The original script does not have that error.&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2020 14:31:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Applymap-does-not-return-the-correct-field-value/m-p/1687331#M52367</guid>
      <dc:creator>43918084</dc:creator>
      <dc:date>2020-03-24T14:31:38Z</dc:date>
    </item>
    <item>
      <title>Re: Applymap does not return the correct field value</title>
      <link>https://community.qlik.com/t5/App-Development/Applymap-does-not-return-the-correct-field-value/m-p/1687364#M52370</link>
      <description>&lt;P&gt;Can you post the actual script you are using? There are other typos in the section you've posted&lt;/P&gt;&lt;P&gt;"Dealno&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;)"&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;[Table] (colon missing)&lt;/P&gt;&lt;P&gt;as FXFO&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;,&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;in your resulting Table, do you get what you expect in the field&amp;nbsp; AL_deal#? Do you actually get anything in the field&amp;nbsp;FXFO?&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2020 15:27:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Applymap-does-not-return-the-correct-field-value/m-p/1687364#M52370</guid>
      <dc:creator>lorenzoconforti</dc:creator>
      <dc:date>2020-03-24T15:27:20Z</dc:date>
    </item>
    <item>
      <title>Re: Applymap does not return the correct field value</title>
      <link>https://community.qlik.com/t5/App-Development/Applymap-does-not-return-the-correct-field-value/m-p/1687419#M52374</link>
      <description>&lt;P&gt;&lt;FONT face="Calibri" size="2"&gt;I Apologize for the mistake as I face some difficulties pasting the information here.&amp;nbsp; Thank you very much for your patience and guidance&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Calibri" size="2"&gt;Please find below the original table&lt;/FONT&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;[FXFO]:
Mapping
LOAD
"Asset/Liab Indicator" &amp;amp; '-' &amp;amp; "Trade ID" as  AL_deal#, 
    "Type We Pay/Receive" as FXFO
FROM [lib://test/CAO_MPMSWBTP_HK_20191231_141815.xlsm]
(ooxml, embedded labels, table is CAO_MPMSWBTP_HK_20191231_141815);

[LYCM]:
LOAD
  iF(left("Nominal AC",1)='1','A', if(left("Nominal AC",1)='2','L','na')) &amp;amp;'-'&amp;amp; "DealNo" as AL_deal#, 
 applymap('FXFO',iF(left("Nominal AC",1)='1','A', if(left("Nominal AC",1)='2','L','na')) &amp;amp;'-'&amp;amp; "DealNo") as FXFO,
"Nominal AC",
"Product Owner",
"DealNO",
 "PARENT ACRONYM "
FROM [lib://test/SAL LY.csv]
(txt, codepage is 28591, embedded labels, delimiter is ',', msq);&lt;/LI-CODE&gt;&lt;P&gt;&lt;FONT face="Calibri" size="2"&gt;&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2020 18:24:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Applymap-does-not-return-the-correct-field-value/m-p/1687419#M52374</guid>
      <dc:creator>43918084</dc:creator>
      <dc:date>2020-03-24T18:24:27Z</dc:date>
    </item>
    <item>
      <title>Re: Applymap does not return the correct field value</title>
      <link>https://community.qlik.com/t5/App-Development/Applymap-does-not-return-the-correct-field-value/m-p/1687485#M52381</link>
      <description>&lt;P&gt;It's returning the key you are using for the mapping (i.e.&amp;nbsp; the second argument in the applymap function), not the first field in the mapping table; it's happening as it's not finding the mapping matches. There is something wrong either with your mapping table or your main table&lt;/P&gt;&lt;P&gt;Just run this and check the two tables to make sure the AL_deal# fields actually match&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;[FXFO]:
//Mapping
LOAD
"Asset/Liab Indicator" &amp;amp; '-' &amp;amp; "Trade ID" as  AL_deal#, 
    "Type We Pay/Receive" as FXFO
FROM [lib://test/CAO_MPMSWBTP_HK_20191231_141815.xlsm]
(ooxml, embedded labels, table is CAO_MPMSWBTP_HK_20191231_141815);

[LYCM]:
LOAD
  iF(left("Nominal AC",1)='1','A', if(left("Nominal AC",1)='2','L','na')) &amp;amp;'-'&amp;amp; "DealNo" as AL_deal#, 
 //applymap('FXFO',iF(left("Nominal AC",1)='1','A', if(left("Nominal AC",1)='2','L','na')) &amp;amp;'-'&amp;amp; "DealNo") as FXFO,
"Nominal AC",
"Product Owner",
"DealNO",
 "PARENT ACRONYM "
FROM [lib://test/SAL LY.csv]
(txt, codepage is 28591, embedded labels, delimiter is ',', msq);&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2020 22:38:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Applymap-does-not-return-the-correct-field-value/m-p/1687485#M52381</guid>
      <dc:creator>lorenzoconforti</dc:creator>
      <dc:date>2020-03-24T22:38:54Z</dc:date>
    </item>
  </channel>
</rss>

