<?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: Define a new field while loading data in QV using if statement in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Define-a-new-field-while-loading-data-in-QV-using-if-statement/m-p/2011274#M83622</link>
    <description>&lt;P&gt;Hi &lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/209102"&gt;@hossein61&lt;/a&gt; &lt;/P&gt;
&lt;P&gt;used load inside load, &lt;/P&gt;
&lt;P&gt;try this - &lt;BR /&gt;&lt;BR /&gt;Table1:&lt;/P&gt;
&lt;P&gt;*, &lt;SPAN&gt;if (Flag1&amp;gt;3 and Flag2=1), Price,0) as price2 ;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;load .... from DB...;&lt;/P&gt;</description>
    <pubDate>Thu, 01 Dec 2022 07:38:15 GMT</pubDate>
    <dc:creator>MendyS</dc:creator>
    <dc:date>2022-12-01T07:38:15Z</dc:date>
    <item>
      <title>Define a new field while loading data in QV using if statement</title>
      <link>https://community.qlik.com/t5/App-Development/Define-a-new-field-while-loading-data-in-QV-using-if-statement/m-p/2011260#M83620</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;
&lt;P&gt;In my DB, I have "Price", "Flag1" and "Flag2" fields. I want to create a new field "Price2" while loading data in QV which contains Prices that meet following criterias:&lt;/P&gt;
&lt;P&gt;Flag1&amp;gt;3 and Flag2=1.&lt;/P&gt;
&lt;P&gt;In other words for a record: if Flag1&amp;gt;3 and Flag2=1, Price2 should be same as Price. Else, Price2 should be '0'.&lt;/P&gt;
&lt;P&gt;How could I do this?&lt;/P&gt;
&lt;P&gt;Hossein&lt;/P&gt;
&lt;P&gt; &lt;/P&gt;</description>
      <pubDate>Thu, 01 Dec 2022 07:05:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Define-a-new-field-while-loading-data-in-QV-using-if-statement/m-p/2011260#M83620</guid>
      <dc:creator>hossein61</dc:creator>
      <dc:date>2022-12-01T07:05:43Z</dc:date>
    </item>
    <item>
      <title>Re: Define a new field while loading data in QV using if statement</title>
      <link>https://community.qlik.com/t5/App-Development/Define-a-new-field-while-loading-data-in-QV-using-if-statement/m-p/2011272#M83621</link>
      <description>&lt;P&gt;HI ,&lt;/P&gt;
&lt;P&gt;In you load script add a new line&lt;/P&gt;
&lt;P&gt;IF( Flag1 &amp;gt; 3 and Flag2=1, Price,0) as Price2&lt;/P&gt;
&lt;P&gt;Depend where you add the line you may need a comma at the end&lt;/P&gt;</description>
      <pubDate>Thu, 01 Dec 2022 07:37:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Define-a-new-field-while-loading-data-in-QV-using-if-statement/m-p/2011272#M83621</guid>
      <dc:creator>Mark_Little</dc:creator>
      <dc:date>2022-12-01T07:37:05Z</dc:date>
    </item>
    <item>
      <title>Re: Define a new field while loading data in QV using if statement</title>
      <link>https://community.qlik.com/t5/App-Development/Define-a-new-field-while-loading-data-in-QV-using-if-statement/m-p/2011274#M83622</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/209102"&gt;@hossein61&lt;/a&gt; &lt;/P&gt;
&lt;P&gt;used load inside load, &lt;/P&gt;
&lt;P&gt;try this - &lt;BR /&gt;&lt;BR /&gt;Table1:&lt;/P&gt;
&lt;P&gt;*, &lt;SPAN&gt;if (Flag1&amp;gt;3 and Flag2=1), Price,0) as price2 ;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;load .... from DB...;&lt;/P&gt;</description>
      <pubDate>Thu, 01 Dec 2022 07:38:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Define-a-new-field-while-loading-data-in-QV-using-if-statement/m-p/2011274#M83622</guid>
      <dc:creator>MendyS</dc:creator>
      <dc:date>2022-12-01T07:38:15Z</dc:date>
    </item>
  </channel>
</rss>

