<?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: Comparing 2 date fields set analysis in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Comparing-2-date-fields-set-analysis/m-p/881044#M307433</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You might be running into another problem: &lt;A _jive_internal="true" href="https://community.qlik.com/docs/DOC-4563" style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3778c7; background-color: #f8fbfe;"&gt;set_analysis_intra-record.qvw&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If both date fields are part of the same data table you create in the load script then you should add a flag field in this table:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; EmployeeID,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Employee Last Date],&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; StartTime_Date,&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if([Employee Last Date] &amp;lt;= StartTime_Date, 1, 0) As FlagField,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ...other fields...&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;FROM ....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can then use this field in your set analysis expression instead: sum({&amp;lt;FlagField={1}&amp;gt;}Revenue)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 18 May 2015 14:32:38 GMT</pubDate>
    <dc:creator>Gysbert_Wassenaar</dc:creator>
    <dc:date>2015-05-18T14:32:38Z</dc:date>
    <item>
      <title>Comparing 2 date fields set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Comparing-2-date-fields-set-analysis/m-p/881043#M307432</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have tried to find an example for what seems like a basic set analysis expression - but can't find one that matches what I need. Just trying to return Revenue where the&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Employee Last Date is &amp;lt;= StartTime_Date&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;but obviously my syntax is wrong. some of the examples I tried:&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;Sum ({&amp;lt;[Employee Last Date]={'&amp;lt;=$(=Date(([StartTime_Date])))'&amp;gt;}Revenue) &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;Sum({&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;SPAN style="color: #800000;"&gt;[Employee Last Date]&lt;/SPAN&gt;={'&amp;lt;=$(Date([StartTime_Date]))'&amp;gt;}Revenue&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt;"&gt;) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;Sum({&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;SPAN style="color: #800000;"&gt;[Employee Last Date]&lt;/SPAN&gt;={'&amp;lt;=[StartTime_Date]'&amp;gt;}Revenue&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt;"&gt;) &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Steve&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2015 14:21:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Comparing-2-date-fields-set-analysis/m-p/881043#M307432</guid>
      <dc:creator>zagzebski</dc:creator>
      <dc:date>2015-05-18T14:21:10Z</dc:date>
    </item>
    <item>
      <title>Re: Comparing 2 date fields set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Comparing-2-date-fields-set-analysis/m-p/881044#M307433</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You might be running into another problem: &lt;A _jive_internal="true" href="https://community.qlik.com/docs/DOC-4563" style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3778c7; background-color: #f8fbfe;"&gt;set_analysis_intra-record.qvw&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If both date fields are part of the same data table you create in the load script then you should add a flag field in this table:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; EmployeeID,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Employee Last Date],&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; StartTime_Date,&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if([Employee Last Date] &amp;lt;= StartTime_Date, 1, 0) As FlagField,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ...other fields...&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;FROM ....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can then use this field in your set analysis expression instead: sum({&amp;lt;FlagField={1}&amp;gt;}Revenue)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2015 14:32:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Comparing-2-date-fields-set-analysis/m-p/881044#M307433</guid>
      <dc:creator>Gysbert_Wassenaar</dc:creator>
      <dc:date>2015-05-18T14:32:38Z</dc:date>
    </item>
    <item>
      <title>Re: Comparing 2 date fields set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Comparing-2-date-fields-set-analysis/m-p/881045#M307434</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;Sum ({&amp;lt;[Employee Last Date]={'&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;[Employee Last Date]&amp;lt;=&lt;/SPAN&gt;[StartTime_Date]'&amp;gt;}Revenue)&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2015 14:33:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Comparing-2-date-fields-set-analysis/m-p/881045#M307434</guid>
      <dc:creator>pokassov</dc:creator>
      <dc:date>2015-05-18T14:33:06Z</dc:date>
    </item>
    <item>
      <title>Re: Comparing 2 date fields set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Comparing-2-date-fields-set-analysis/m-p/881046#M307435</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks. Think Gyspert caught my issue.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2015 15:21:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Comparing-2-date-fields-set-analysis/m-p/881046#M307435</guid>
      <dc:creator>zagzebski</dc:creator>
      <dc:date>2015-05-18T15:21:05Z</dc:date>
    </item>
    <item>
      <title>Re: Comparing 2 date fields set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Comparing-2-date-fields-set-analysis/m-p/881047#M307436</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Very helpful document. I all the Set analysis trainings I have experienced nobody went through this. Thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2015 15:29:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Comparing-2-date-fields-set-analysis/m-p/881047#M307436</guid>
      <dc:creator>zagzebski</dc:creator>
      <dc:date>2015-05-18T15:29:05Z</dc:date>
    </item>
    <item>
      <title>Re: Comparing 2 date fields set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Comparing-2-date-fields-set-analysis/m-p/881048#M307437</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I do have one question.&amp;nbsp; In your example would everythign still apply if you took out (1) OrderDate, (2) Shipdate or (3) both OrderDate and ShipDate from your table. Would that change how your set would work?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2015 15:34:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Comparing-2-date-fields-set-analysis/m-p/881048#M307437</guid>
      <dc:creator>zagzebski</dc:creator>
      <dc:date>2015-05-18T15:34:03Z</dc:date>
    </item>
  </channel>
</rss>

