<?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 Problems with Conditional Function IF in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Problems-with-Conditional-Function-IF/m-p/222419#M75092</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;the syntax for if is :&lt;/P&gt;&lt;P style="font-style: italic"&gt;IF( condition, value_if_condition_is_true, value_if_condition_is_false)&lt;/P&gt;&lt;P&gt;IF(0=1, 'dog', 'cat') is 'cat'&lt;/P&gt;&lt;P&gt;it works like the ternary operator "?" in C&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 26 Jan 2010 14:31:06 GMT</pubDate>
    <dc:creator />
    <dc:date>2010-01-26T14:31:06Z</dc:date>
    <item>
      <title>Problems with Conditional Function IF</title>
      <link>https://community.qlik.com/t5/QlikView/Problems-with-Conditional-Function-IF/m-p/222417#M75090</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I want to use the If function, but when I reload the script it appears a message that says Script line error:&lt;BR /&gt;if(num(month(today())) = 1)&lt;/P&gt;&lt;P&gt;The script is the following:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if(num(month(today())) = 1)&lt;BR /&gt;//si es enero, considero el cambio de año como un caso particular&lt;BR /&gt; //genera el QVD correspondiente a diciembre del año pasado&lt;BR /&gt; Año = year(today()) - 1;&lt;BR /&gt;&lt;BR /&gt; Transacciones_ACA_Sum:&lt;BR /&gt; NOCONCATENATE&lt;BR /&gt; LOAD&lt;BR /&gt; FFECHA,&lt;BR /&gt; SKU,&lt;BR /&gt; NODO,&lt;BR /&gt; Sum(CAJAS) as CAJAS,&lt;BR /&gt; Sum(NIV) as NIV,&lt;BR /&gt; Sum(KILOS) as KILOS&lt;BR /&gt; RESIDENT Transacciones_TPM&lt;BR /&gt; WHERE YEAR(FFECHA) = $(Año) AND MONTH(FFECHA) = 12&lt;BR /&gt; GROUP BY&lt;BR /&gt; FFECHA,&lt;BR /&gt; SKU,&lt;BR /&gt; NODO;&lt;BR /&gt;&lt;BR /&gt; STORE Transacciones_ACA_Sum INTO $(vPathBase)\QVD\Transacciones_ACA_Sum\Transacciones_ACA_Sum_$(Año)_12.QVD;&lt;BR /&gt; DROP TABLE Transacciones_ACA_Sum;&lt;/P&gt;&lt;P&gt;I thing I´m writing bad the If condition, what do you think?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Francisco&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 26 Jan 2010 13:45:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Problems-with-Conditional-Function-IF/m-p/222417#M75090</guid>
      <dc:creator />
      <dc:date>2010-01-26T13:45:00Z</dc:date>
    </item>
    <item>
      <title>Problems with Conditional Function IF</title>
      <link>https://community.qlik.com/t5/QlikView/Problems-with-Conditional-Function-IF/m-p/222418#M75091</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Maybe you just forgot the "then" and end if&lt;/P&gt;&lt;P&gt;Try this&lt;/P&gt;&lt;P&gt;if(num(month(today))=1) &lt;B&gt;then&lt;/B&gt;&lt;/P&gt;&lt;P&gt;youre code&lt;/P&gt;&lt;P style="font-weight: bold"&gt;end if&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 26 Jan 2010 13:53:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Problems-with-Conditional-Function-IF/m-p/222418#M75091</guid>
      <dc:creator />
      <dc:date>2010-01-26T13:53:08Z</dc:date>
    </item>
    <item>
      <title>Problems with Conditional Function IF</title>
      <link>https://community.qlik.com/t5/QlikView/Problems-with-Conditional-Function-IF/m-p/222419#M75092</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;the syntax for if is :&lt;/P&gt;&lt;P style="font-style: italic"&gt;IF( condition, value_if_condition_is_true, value_if_condition_is_false)&lt;/P&gt;&lt;P&gt;IF(0=1, 'dog', 'cat') is 'cat'&lt;/P&gt;&lt;P&gt;it works like the ternary operator "?" in C&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 26 Jan 2010 14:31:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Problems-with-Conditional-Function-IF/m-p/222419#M75092</guid>
      <dc:creator />
      <dc:date>2010-01-26T14:31:06Z</dc:date>
    </item>
    <item>
      <title>Problems with Conditional Function IF</title>
      <link>https://community.qlik.com/t5/QlikView/Problems-with-Conditional-Function-IF/m-p/222420#M75093</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks, I tried to do that, but appears the following message:&lt;/P&gt;&lt;P&gt;Script line error:&lt;BR /&gt;if(num(month(today())) = 1)&lt;/P&gt;&lt;P&gt;Unknown statement&lt;BR /&gt;then&lt;BR /&gt; Año = year(today()) - 1&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Francisco&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 26 Jan 2010 15:19:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Problems-with-Conditional-Function-IF/m-p/222420#M75093</guid>
      <dc:creator />
      <dc:date>2010-01-26T15:19:24Z</dc:date>
    </item>
  </channel>
</rss>

