<?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: Set Analysis Comparing 2 Dates in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Set-Analysis-Comparing-2-Dates/m-p/2430802#M96571</link>
    <description>&lt;P&gt;Hi,&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/29554"&gt;@dthornburg&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;The function below did not work due to errors in the syntax of the written expression.&lt;/P&gt;
&lt;P&gt;It was confusing to understand the model presented and what you want to achieve, but I followed the example of the expression presented.&lt;/P&gt;
&lt;P&gt;See it this way&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;PRE id="tw-target-text" class="tw-data-text tw-text-large tw-ta" dir="ltr" data-placeholder="Tradução" data-ved="2ahUKEwjji_D65vOEAxXAlpUCHfZlCtYQ3ewLegQIBRAU"&gt;&lt;SPAN class="Y2IQFc"&gt;Sum({1&amp;lt;PLN_StartDate={"&amp;gt;=PLN_CycStartDate&amp;lt;=PLN_StartDate"}&amp;gt;}&lt;SPAN&gt;PLN_QtyOrdered&lt;/SPAN&gt;)&lt;/SPAN&gt;&lt;/PRE&gt;
&lt;P&gt;You may need to change something regarding the date period fields, as I said I don't understand very well, but I hope it helps to give you some guidance on the solution.&lt;BR /&gt;&lt;BR /&gt;Regarts,&lt;BR /&gt;Matheus&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 14 Mar 2024 13:03:38 GMT</pubDate>
    <dc:creator>MatheusC</dc:creator>
    <dc:date>2024-03-14T13:03:38Z</dc:date>
    <item>
      <title>Set Analysis Comparing 2 Dates</title>
      <link>https://community.qlik.com/t5/App-Development/Set-Analysis-Comparing-2-Dates/m-p/2430767#M96567</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;I am trying to total a group of orders that fall within a planned Cycle. I have the starting dates of each cycle and the start date for each order. Cycle is when we plan on running on the orders for a given family(First column in Planning detail). Trying something like below. How do I compare to the next cycle date. calculation below is not even working. Any help would be appreciated.&lt;/P&gt;
&lt;P&gt;Sum({1&amp;lt;,PLN_StartDate={"=PLN_StartDate&amp;gt;=PLN_CycStartDate"}&amp;gt;}SUM(PLN_QtyOrdered))&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="dthornburg_0-1710417787284.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/161990i26E04A55819FE871/image-size/medium?v=v2&amp;amp;px=400" role="button" title="dthornburg_0-1710417787284.png" alt="dthornburg_0-1710417787284.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Mar 2024 12:08:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Set-Analysis-Comparing-2-Dates/m-p/2430767#M96567</guid>
      <dc:creator>dthornburg</dc:creator>
      <dc:date>2024-03-14T12:08:41Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis Comparing 2 Dates</title>
      <link>https://community.qlik.com/t5/App-Development/Set-Analysis-Comparing-2-Dates/m-p/2430799#M96570</link>
      <description>&lt;P&gt;Is it possible to calculate an 'End Date' for each cycle. If you have&amp;nbsp; Start and End data for each cycle, you could perform an intervalmatch() which automatically forms a data model link from the order start date to the cycle whose start/end date range matches.&amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Once the link is in the data model, its very easy to calculate what you are after.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://help.qlik.com/en-US/sense/February2024/Subsystems/Hub/Content/Sense_Hub/Scripting/ScriptPrefixes/IntervalMatch.htm#:~:text=The%20IntervalMatch%20prefix%20is%20used,one%20or%20several%20additional%20keys.&amp;amp;text=The%20IntervalMatch%20prefix%20must%20be,statement%20that%20loads%20the%20intervals" target="_blank"&gt;https://help.qlik.com/en-US/sense/February2024/Subsystems/Hub/Content/Sense_Hub/Scripting/ScriptPrefixes/IntervalMatch.htm#:~:text=The%20IntervalMatch%20prefix%20is%20used,one%20or%20several%20additional%20keys.&amp;amp;text=The%20IntervalMatch%20prefix%20must%20be,statement%20that%20loads%20the%20intervals&lt;/A&gt;.&lt;/P&gt;</description>
      <pubDate>Thu, 14 Mar 2024 13:01:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Set-Analysis-Comparing-2-Dates/m-p/2430799#M96570</guid>
      <dc:creator>JonnyPoole</dc:creator>
      <dc:date>2024-03-14T13:01:47Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis Comparing 2 Dates</title>
      <link>https://community.qlik.com/t5/App-Development/Set-Analysis-Comparing-2-Dates/m-p/2430802#M96571</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/29554"&gt;@dthornburg&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;The function below did not work due to errors in the syntax of the written expression.&lt;/P&gt;
&lt;P&gt;It was confusing to understand the model presented and what you want to achieve, but I followed the example of the expression presented.&lt;/P&gt;
&lt;P&gt;See it this way&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;PRE id="tw-target-text" class="tw-data-text tw-text-large tw-ta" dir="ltr" data-placeholder="Tradução" data-ved="2ahUKEwjji_D65vOEAxXAlpUCHfZlCtYQ3ewLegQIBRAU"&gt;&lt;SPAN class="Y2IQFc"&gt;Sum({1&amp;lt;PLN_StartDate={"&amp;gt;=PLN_CycStartDate&amp;lt;=PLN_StartDate"}&amp;gt;}&lt;SPAN&gt;PLN_QtyOrdered&lt;/SPAN&gt;)&lt;/SPAN&gt;&lt;/PRE&gt;
&lt;P&gt;You may need to change something regarding the date period fields, as I said I don't understand very well, but I hope it helps to give you some guidance on the solution.&lt;BR /&gt;&lt;BR /&gt;Regarts,&lt;BR /&gt;Matheus&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Mar 2024 13:03:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Set-Analysis-Comparing-2-Dates/m-p/2430802#M96571</guid>
      <dc:creator>MatheusC</dc:creator>
      <dc:date>2024-03-14T13:03:38Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis Comparing 2 Dates</title>
      <link>https://community.qlik.com/t5/App-Development/Set-Analysis-Comparing-2-Dates/m-p/2430946#M96587</link>
      <description>&lt;P&gt;Assume I have 2 records in the Cycle schedule table. Record 1 has a start date of 12/7/2023 and record 2 has a start date of 1/29/2024. I then have many records in another table that have start dates. The goal is to total all the records in 2nd table that are between the 2 start dates for each cycle record. In example I posted. if a pln_compl_date is between 1 start date and the next start date it is included in the 1st record.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Something like below but the last portion id looking at the next cycle schedule date.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Sum({1&amp;lt;,PLN_StartDate={"=PLN_StartDate&amp;gt;=PLN_CycStartDate"} AND PLN_StartDate={"=PLN_StartDate&amp;gt;=PLN_CycStartDate" }&amp;gt;}SUM(PLN_QtyOrdered))&lt;/P&gt;</description>
      <pubDate>Thu, 14 Mar 2024 17:02:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Set-Analysis-Comparing-2-Dates/m-p/2430946#M96587</guid>
      <dc:creator>dthornburg</dc:creator>
      <dc:date>2024-03-14T17:02:03Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis Comparing 2 Dates</title>
      <link>https://community.qlik.com/t5/App-Development/Set-Analysis-Comparing-2-Dates/m-p/2430948#M96588</link>
      <description>&lt;P&gt;I would use script logic to read record 1 and record 2 into a new (3rd) table in order to produce a singlerecord that has an start and end date where the start date is the start date from record 1 and the end date is the start date from record 2. Then... use intervalmatch() to form a link between the dates in the 2nd table and the interval in the 3rd table.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you have sample data I can show you. It may be possible to achieve this through If logic and set analysis but it strikes me as burdensome and possibly slow to render&lt;/P&gt;</description>
      <pubDate>Thu, 14 Mar 2024 17:09:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Set-Analysis-Comparing-2-Dates/m-p/2430948#M96588</guid>
      <dc:creator>JonnyPoole</dc:creator>
      <dc:date>2024-03-14T17:09:57Z</dc:date>
    </item>
  </channel>
</rss>

