<?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: How to equate two dates in Set expression in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487326#M1125871</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;After formatting both dates to a MonthName, as others have suggested, I believe the SA syntax will be&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=Count({&amp;lt;OrderMonth = DeliveryMonth&amp;gt;} OrderId)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 10 Jan 2014 05:43:27 GMT</pubDate>
    <dc:creator>rwunderlich</dc:creator>
    <dc:date>2014-01-10T05:43:27Z</dc:date>
    <item>
      <title>How to equate two dates in Set expression</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487318#M1125863</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As per the requirement, i want to show the number of products placed and delivered on the same month.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If order placed=100 (dec)&lt;/P&gt;&lt;P&gt; and order delivered =70(dec)&amp;nbsp; 70 orders should be among 100 orders placed in dec&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I want the percentage of order delivered/ order placed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i.e, Order placed and order delivered in dec/ order placed&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We can do this comparing two different dates, orderplaced date=dec, and orderplaced and delivered=dec,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Am not able to achieve this,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anyone help me to solve this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks and Regards,&lt;/P&gt;&lt;P&gt;Smitha&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 09 Jan 2014 11:07:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487318#M1125863</guid>
      <dc:creator />
      <dc:date>2014-01-09T11:07:03Z</dc:date>
    </item>
    <item>
      <title>Re: How to equate two dates in Set expression</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487319#M1125864</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Smitha,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;can you give an example of how your date_placed and date_delivered look like?&lt;/P&gt;&lt;P&gt;Generally, that should work using set_expression. You just have to make sure both dates have the same format so QlikView can compare them.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HTH&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DataNibbler&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 09 Jan 2014 11:11:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487319#M1125864</guid>
      <dc:creator>datanibbler</dc:creator>
      <dc:date>2014-01-09T11:11:26Z</dc:date>
    </item>
    <item>
      <title>Re: Re: How to equate two dates in Set expression</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487320#M1125865</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;BR /&gt;I really dont have to compare both the dates.&lt;/P&gt;&lt;P&gt;I want to have the order count placedin particular month and the same orders which are delivered on the same month.&lt;/P&gt;&lt;P&gt;If 100 orders placed in Dec, 70 out of 100 delivered in dec&lt;/P&gt;&lt;P&gt;i need to calculate the percentage of 70/100&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am attaching xls for your reference.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;let me know if you need any more information concern to above issue.&lt;/P&gt;&lt;P&gt;Thanks and Regards,&lt;/P&gt;&lt;P&gt;Smitha&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 09 Jan 2014 11:56:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487320#M1125865</guid>
      <dc:creator />
      <dc:date>2014-01-09T11:56:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to equate two dates in Set expression</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487321#M1125866</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Smitha,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;well, how do you want to define whether or not the two dates are in the same month without comparing them? &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As I said, you have to make sure they both have the same format using the DATE() function. Better use the floor() function, too to cut off that time_part.&lt;/P&gt;&lt;P&gt;Then you can cut the year_month_part out of that to make sure the two dates are in the same year and the same month.&lt;/P&gt;&lt;P&gt;Try something like&lt;/P&gt;&lt;P&gt;MID(DATE(floor([placed]), 'DD/MM/YY'), 4, 5) - that will give you sth like &amp;gt;&amp;gt;&amp;gt; 09/13 &amp;lt;&amp;lt;&amp;lt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You would need two formulas like this in your set_expression - one for each of your dates. Unfortunately I don't know how to do that - I'd suggest re-formatting (or even both) of the dates like that in the script - test it first, e.g. in a textbox or in a listbox_object before putting it in the script. Then you'll have one or two native fields that you can easily compare (set_to_be_equal) in a set_expression.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think once you have the nr. of orders placed and delivered in the same month, getting the percentage of the orders_placed will be easy.&lt;/P&gt;&lt;P&gt;HTH&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DataNibbler&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 09 Jan 2014 12:38:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487321#M1125866</guid>
      <dc:creator>datanibbler</dc:creator>
      <dc:date>2014-01-09T12:38:45Z</dc:date>
    </item>
    <item>
      <title>Re: How to equate two dates in Set expression</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487322#M1125867</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I can handle the date format, the main challenge is how to put the condition orderplaced and order delivered in the same month.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks and Regards,&lt;/P&gt;&lt;P&gt;Smitha&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Jan 2014 02:59:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487322#M1125867</guid>
      <dc:creator />
      <dc:date>2014-01-10T02:59:50Z</dc:date>
    </item>
    <item>
      <title>Re: Re: How to equate two dates in Set expression</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487323#M1125868</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use IF condition instead of Set analysis.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For your scenario, you need to verify &lt;STRONG&gt;Row wise, &lt;/STRONG&gt;I don't think set analysis will do this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Karthik&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Jan 2014 04:05:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487323#M1125868</guid>
      <dc:creator />
      <dc:date>2014-01-10T04:05:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to equate two dates in Set expression</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487324#M1125869</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;Arrive a flag in script like this&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;&amp;nbsp; *,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; If(MonthName(Orderdelivered) = MonthName(Orderplaced), 1, 0) AS Flag&lt;/P&gt;&lt;P&gt;FROM DataSource;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now in expression just use&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=Count({&amp;lt;Flag={1}&amp;gt;}Order_ID)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Jagan.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Jan 2014 04:19:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487324#M1125869</guid>
      <dc:creator>jagan</dc:creator>
      <dc:date>2014-01-10T04:19:15Z</dc:date>
    </item>
    <item>
      <title>Re: How to equate two dates in Set expression</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487325#M1125870</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Count({$&amp;lt;Date={=$(=OrderPlaced=OrderDelivered)}&amp;gt;}Order_ID)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Where Date is your Calender Date&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Jan 2014 04:45:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487325#M1125870</guid>
      <dc:creator>brijesh1991</dc:creator>
      <dc:date>2014-01-10T04:45:40Z</dc:date>
    </item>
    <item>
      <title>Re: How to equate two dates in Set expression</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487326#M1125871</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;After formatting both dates to a MonthName, as others have suggested, I believe the SA syntax will be&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=Count({&amp;lt;OrderMonth = DeliveryMonth&amp;gt;} OrderId)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Jan 2014 05:43:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-equate-two-dates-in-Set-expression/m-p/487326#M1125871</guid>
      <dc:creator>rwunderlich</dc:creator>
      <dc:date>2014-01-10T05:43:27Z</dc:date>
    </item>
  </channel>
</rss>

