<?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 Set identifiers in a If statement in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Set-identifiers-in-a-If-statement/m-p/676394#M476173</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Everybody,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am a new QlikView developper and I have a problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I load data in which there are three columns. The first column is registration_date and the second one is treatment_date and the last one is number_of_folder.&lt;/P&gt;&lt;P&gt;I would like to sum the number_of_folder column every time where registration_date equal treatment_date.&lt;/P&gt;&lt;P&gt;To do it I first wrote this statement :&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Sum( If([registration_date] = [treatment_date], [number_of_folder] )&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;But I didn't work. I noticed that It's just because I had selected a range for registration_date and treatment_date both using a slider and It wasn't what I should do. I have to evaluate this activity without taking in account the selected treatment_date (It's used for another operation) but by using the selected registration_date &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So, I try this statement where I try to specify the full data set using Set Analysis statement by hoping that in the If Statement, the comparaison between the two column date will be base from the full data set not from the data set obtained after selecting date but it doesn't work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Sum( {1&amp;lt;[registration_date] = P([treatment_date]), [treatment_date]={"*"}&amp;gt;} If([registration_date]=[treatment_date], [number_of_folder]) )&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Please how could I do it ? Thanks.&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 13 Jun 2014 11:46:40 GMT</pubDate>
    <dc:creator />
    <dc:date>2014-06-13T11:46:40Z</dc:date>
    <item>
      <title>Set identifiers in a If statement</title>
      <link>https://community.qlik.com/t5/QlikView/Set-identifiers-in-a-If-statement/m-p/676394#M476173</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Everybody,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am a new QlikView developper and I have a problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I load data in which there are three columns. The first column is registration_date and the second one is treatment_date and the last one is number_of_folder.&lt;/P&gt;&lt;P&gt;I would like to sum the number_of_folder column every time where registration_date equal treatment_date.&lt;/P&gt;&lt;P&gt;To do it I first wrote this statement :&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Sum( If([registration_date] = [treatment_date], [number_of_folder] )&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;But I didn't work. I noticed that It's just because I had selected a range for registration_date and treatment_date both using a slider and It wasn't what I should do. I have to evaluate this activity without taking in account the selected treatment_date (It's used for another operation) but by using the selected registration_date &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So, I try this statement where I try to specify the full data set using Set Analysis statement by hoping that in the If Statement, the comparaison between the two column date will be base from the full data set not from the data set obtained after selecting date but it doesn't work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Sum( {1&amp;lt;[registration_date] = P([treatment_date]), [treatment_date]={"*"}&amp;gt;} If([registration_date]=[treatment_date], [number_of_folder]) )&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Please how could I do it ? Thanks.&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Jun 2014 11:46:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-identifiers-in-a-If-statement/m-p/676394#M476173</guid>
      <dc:creator />
      <dc:date>2014-06-13T11:46:40Z</dc:date>
    </item>
    <item>
      <title>Re: Set identifiers in a If statement</title>
      <link>https://community.qlik.com/t5/QlikView/Set-identifiers-in-a-If-statement/m-p/676395#M476174</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;=Sum( {&amp;lt; [treatment_date]=&amp;gt;} If([registration_date]=[treatment_date], [number_of_folder]) )&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Jun 2014 11:52:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-identifiers-in-a-If-statement/m-p/676395#M476174</guid>
      <dc:creator>tresB</dc:creator>
      <dc:date>2014-06-13T11:52:55Z</dc:date>
    </item>
    <item>
      <title>Re: Set identifiers in a If statement</title>
      <link>https://community.qlik.com/t5/QlikView/Set-identifiers-in-a-If-statement/m-p/676396#M476175</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;STRONG style="color: #3d3d3d; background: white; font-size: 10.0pt; font-family: 'Helvetica','sans-serif';"&gt;Sum&lt;/STRONG&gt;&lt;SPAN lang="EN-US" style="font-size: 11.0pt; font-family: 'Segoe Print';"&gt;({&amp;lt;&lt;/SPAN&gt;&lt;STRONG style="color: #3d3d3d; background: white; font-size: 10.0pt; font-family: 'Helvetica','sans-serif';"&gt;[number_of_folder]&lt;/STRONG&gt;&lt;SPAN lang="EN-US" style="font-size: 11.0pt; font-family: 'Segoe Print';"&gt;={"&lt;/SPAN&gt;&lt;STRONG&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Helvetica','sans-serif'; color: #3d3d3d; background: white;"&gt;[registration_date]&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;SPAN class="apple-converted-space"&gt;&lt;STRONG style="color: #3d3d3d; background: white; font-size: 10.0pt; font-family: 'Helvetica','sans-serif';"&gt; =&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG style="color: #3d3d3d; background: white; font-size: 10.0pt; font-family: 'Helvetica','sans-serif';"&gt;[treatment_date]&lt;/STRONG&gt;&lt;SPAN lang="EN-US" style="font-size: 11.0pt; font-family: 'Segoe Print';"&gt;" }&amp;gt;} &lt;/SPAN&gt;&lt;STRONG style="color: #3d3d3d; background: white; font-size: 10.0pt; font-family: 'Helvetica','sans-serif';"&gt;[number_of_folder]&lt;/STRONG&gt;&lt;SPAN lang="EN-US" style="font-size: 11.0pt; font-family: 'Segoe Print';"&gt;)&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Jun 2014 11:53:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-identifiers-in-a-If-statement/m-p/676396#M476175</guid>
      <dc:creator />
      <dc:date>2014-06-13T11:53:25Z</dc:date>
    </item>
    <item>
      <title>Re: Set identifiers in a If statement</title>
      <link>https://community.qlik.com/t5/QlikView/Set-identifiers-in-a-If-statement/m-p/676397#M476176</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I would create a new field in the script, something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If(&lt;STRONG style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;[registration_date] = [treatment_date]&lt;/STRONG&gt;, &lt;STRONG style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;[number_of_folder]&lt;/STRONG&gt;, 0) AS NewField&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then just sum that field up as usual and it should work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Teemu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Jun 2014 11:57:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-identifiers-in-a-If-statement/m-p/676397#M476176</guid>
      <dc:creator>teempi</dc:creator>
      <dc:date>2014-06-13T11:57:07Z</dc:date>
    </item>
    <item>
      <title>Re: Set identifiers in a If statement</title>
      <link>https://community.qlik.com/t5/QlikView/Set-identifiers-in-a-If-statement/m-p/676398#M476177</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi tresesco,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks but no changes. I get the same results with my statements.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Jun 2014 14:19:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-identifiers-in-a-If-statement/m-p/676398#M476177</guid>
      <dc:creator />
      <dc:date>2014-06-13T14:19:17Z</dc:date>
    </item>
    <item>
      <title>Re: Set identifiers in a If statement</title>
      <link>https://community.qlik.com/t5/QlikView/Set-identifiers-in-a-If-statement/m-p/676399#M476178</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Srashti,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks but it doesn't work. I don't know how the statment works but it gives a result very far from the good result.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Jun 2014 14:20:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-identifiers-in-a-If-statement/m-p/676399#M476178</guid>
      <dc:creator />
      <dc:date>2014-06-13T14:20:52Z</dc:date>
    </item>
    <item>
      <title>Re: Set identifiers in a If statement</title>
      <link>https://community.qlik.com/t5/QlikView/Set-identifiers-in-a-If-statement/m-p/676400#M476179</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes Its a good answer but I couldn't apply this because there are many indicators to calculate based on the same logic. So, just imagine I apply it in a large data sets.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Jun 2014 15:32:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-identifiers-in-a-If-statement/m-p/676400#M476179</guid>
      <dc:creator />
      <dc:date>2014-06-13T15:32:34Z</dc:date>
    </item>
  </channel>
</rss>

