<?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: or expression in combination with &amp;quot;?&amp;quot; operator in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/or-expression-in-combination-with-quot-quot-operator/m-p/2365885#M129445</link>
    <description>&lt;P&gt;I've got a solution. More luck than skill and dirty ... but it works for all fields.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;(null != row1.Premium_Group1?&lt;/P&gt;
&lt;P&gt;(row1.Premium_Group1.contains("Group (group administration/ external audit)")?&lt;BR /&gt;"x":" ") :&lt;/P&gt;
&lt;P&gt;" ")&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;+&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;(null != row1.Premium_Group&lt;FONT color="#FF00FF"&gt;2&lt;/FONT&gt;?&lt;/P&gt;
&lt;P&gt;(row1.Premium_Group&lt;FONT color="#FF00FF"&gt;2&lt;/FONT&gt;.contains("Group (/group administration/ external audit)")?&lt;BR /&gt;"x":" ") :&lt;/P&gt;
&lt;P&gt;" ")&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#FF0000"&gt;+&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#FF0000"&gt;....&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 03 Oct 2017 13:51:10 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2017-10-03T13:51:10Z</dc:date>
    <item>
      <title>or expression in combination with "?" operator</title>
      <link>https://community.qlik.com/t5/Talend-Studio/or-expression-in-combination-with-quot-quot-operator/m-p/2365880#M129440</link>
      <description>&lt;P&gt;Hello everybody,&lt;/P&gt; 
&lt;P&gt;I'm new to Talend and I have a question. Maybe simple...but I don't get it.&lt;/P&gt; 
&lt;P&gt;This is my expression:&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;(null != row1.Premium_Group1?&lt;/P&gt; 
&lt;P&gt;(row1.Premium_Group.contains("Group (group administration/ external audit)")?&lt;BR /&gt;"x":" ") :&lt;/P&gt; 
&lt;P&gt;" ")&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;First he checks for a null value, if not, he checks for the expression "Group (group ad...", if the expression exists "x" if not " ". Works so far.&lt;/P&gt; 
&lt;P&gt;But for the next Ouput field I have to check&amp;nbsp; two input field. So the expression should look like:&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;(null != row1.Premium_Group1?&lt;/P&gt; 
&lt;P&gt;(row1.Premium_Group1.contains("Group (group administration/ external audit)")?&lt;BR /&gt;"x":" ") :&lt;/P&gt; 
&lt;P&gt;" ")&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;or ( || )&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;(null != row1.Premium_Group&lt;FONT color="#FF00FF"&gt;2&lt;/FONT&gt;?&lt;/P&gt; 
&lt;P&gt;(row1.Premium_Group&lt;FONT color="#FF00FF"&gt;2&lt;/FONT&gt;.contains("Group (/group administration/ external audit)")?&lt;BR /&gt;"x":" ") :&lt;/P&gt; 
&lt;P&gt;" ")&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;What kind of expression I have to use instead of "||" . I hope someone can help me &lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009MACn.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/154443iC5B8CACEF3D12C6A/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009MACn.png" alt="0683p000009MACn.png" /&gt;&lt;/span&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;PS: later one I have to check for 5 input fields. So the solution should be scalable.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Cheers,&lt;/P&gt; 
&lt;P&gt;Christian&lt;/P&gt;</description>
      <pubDate>Tue, 03 Oct 2017 10:55:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/or-expression-in-combination-with-quot-quot-operator/m-p/2365880#M129440</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-10-03T10:55:35Z</dc:date>
    </item>
    <item>
      <title>Re: or expression in combination with "?" operator</title>
      <link>https://community.qlik.com/t5/Talend-Studio/or-expression-in-combination-with-quot-quot-operator/m-p/2365881#M129441</link>
      <description>&lt;P&gt;How are you wanting to use your OR here? You are not outputting a boolean, you are outputting a String. So if you want to use the OR you need to provide the logic behind it.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;By the way, you can use OR as || in these conditions&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 03 Oct 2017 11:35:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/or-expression-in-combination-with-quot-quot-operator/m-p/2365881#M129441</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-10-03T11:35:20Z</dc:date>
    </item>
    <item>
      <title>Re: or expression in combination with "?" operator</title>
      <link>https://community.qlik.com/t5/Talend-Studio/or-expression-in-combination-with-quot-quot-operator/m-p/2365882#M129442</link>
      <description>&lt;P&gt;"the or("||") comment isn't a part of my expression. I just wanted to describe my concern. My data source is a questionnaire. I get the data via web API (Json). I have a checkbox question with 6 answers. The Ouput is Json looks like that:&lt;/P&gt; 
&lt;P&gt;"At group level, how was the premium allocated? Please check ": [&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;FONT color="#FF9900"&gt;//Question&lt;/FONT&gt;&lt;BR /&gt;"Group ... (IMS/group administration/ external audit)",&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;FONT color="#FF9900"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; //Answer1&lt;/FONT&gt;&lt;BR /&gt;"Products....( storage)",&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;FONT color="#FF9900"&gt;//Answer2 etc.&lt;/FONT&gt;&lt;BR /&gt;"Basic ....and sanitation"&lt;BR /&gt;]&lt;BR /&gt;The description of an answer (i.e. "Group ... (IMS/group administration/ external audit)") stands for the fact, that the user signed the checkbox. Otherwise the answer isn't part of the Json. In that case the user signed 3 of them.&lt;BR /&gt;Each answer (in total 6) receive its own column in the output table. Now I have to check, If someone choosed i.e. "Group ... (IMS/group administration/ external audit)". For the first column I can use&lt;/P&gt; 
&lt;P&gt;(null != row1.Premium_Group1?&lt;BR /&gt;(row1.Premium_Group1.contains("Group (group administration/ external audit)")?&lt;BR /&gt;"x":" ") :&lt;BR /&gt;" ")&lt;/P&gt; 
&lt;P&gt;That's enough. But when someone in the questionnaire doesn't choose Answer1 but Answer2, Answer2 will be on "Position 1" inside the Json String of the question. So in my second ouput column (to check answer2) I have to add the second part to the expression, to check for position 1 and position 2 inside the Json String&lt;BR /&gt;I'm using tExtractJsonFields and the mapping looks like this:&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Mapping_json.jpg" style="width: 999px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009Lqwi.jpg"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/134486iDF536A095BE2B8B3/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009Lqwi.jpg" alt="0683p000009Lqwi.jpg" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;So all in all I think my solution should work.&amp;nbsp;But I don't know how to use&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;(null != row1.Premium_Group1?&lt;/P&gt; 
&lt;P&gt;(row1.Premium_Group1.contains("Group (group administration/ external audit)")?&lt;BR /&gt;"x":" ") :&lt;/P&gt; 
&lt;P&gt;" ")&lt;/P&gt; 
&lt;P&gt;several times in one expression with different kinds of input fields (positions in the Json).&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;My post was now unfortunately longer than expected. I hope that makes the whole thing more clear.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Cheers,&lt;/P&gt; 
&lt;P&gt;Christian&lt;/P&gt;</description>
      <pubDate>Tue, 03 Oct 2017 13:00:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/or-expression-in-combination-with-quot-quot-operator/m-p/2365882#M129442</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-10-03T13:00:36Z</dc:date>
    </item>
    <item>
      <title>Re: or expression in combination with "?" operator</title>
      <link>https://community.qlik.com/t5/Talend-Studio/or-expression-in-combination-with-quot-quot-operator/m-p/2365883#M129443</link>
      <description>&lt;P&gt;I see. You can maybe use tMap variables to help with this. I have written a tutorial which shows how to move your data dynamically between columns. It is not really what you are doing here, but the methodology might give you a few clues. Take a look here:&amp;nbsp;&lt;A href="https://www.rilhia.com/tutorials/dynamic-column-order" target="_blank" rel="nofollow noopener noreferrer"&gt;https://www.rilhia.com/tutorials/dynamic-column-order&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 03 Oct 2017 13:09:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/or-expression-in-combination-with-quot-quot-operator/m-p/2365883#M129443</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-10-03T13:09:42Z</dc:date>
    </item>
    <item>
      <title>Re: or expression in combination with "?" operator</title>
      <link>https://community.qlik.com/t5/Talend-Studio/or-expression-in-combination-with-quot-quot-operator/m-p/2365884#M129444</link>
      <description>&lt;P&gt;I will check. Thanks.&lt;/P&gt;</description>
      <pubDate>Tue, 03 Oct 2017 13:23:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/or-expression-in-combination-with-quot-quot-operator/m-p/2365884#M129444</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-10-03T13:23:01Z</dc:date>
    </item>
    <item>
      <title>Re: or expression in combination with "?" operator</title>
      <link>https://community.qlik.com/t5/Talend-Studio/or-expression-in-combination-with-quot-quot-operator/m-p/2365885#M129445</link>
      <description>&lt;P&gt;I've got a solution. More luck than skill and dirty ... but it works for all fields.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;(null != row1.Premium_Group1?&lt;/P&gt;
&lt;P&gt;(row1.Premium_Group1.contains("Group (group administration/ external audit)")?&lt;BR /&gt;"x":" ") :&lt;/P&gt;
&lt;P&gt;" ")&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;+&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;(null != row1.Premium_Group&lt;FONT color="#FF00FF"&gt;2&lt;/FONT&gt;?&lt;/P&gt;
&lt;P&gt;(row1.Premium_Group&lt;FONT color="#FF00FF"&gt;2&lt;/FONT&gt;.contains("Group (/group administration/ external audit)")?&lt;BR /&gt;"x":" ") :&lt;/P&gt;
&lt;P&gt;" ")&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#FF0000"&gt;+&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#FF0000"&gt;....&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 03 Oct 2017 13:51:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/or-expression-in-combination-with-quot-quot-operator/m-p/2365885#M129445</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-10-03T13:51:10Z</dc:date>
    </item>
  </channel>
</rss>

