<?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: Condition on Date in Script in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Condition-on-Date-in-Script/m-p/139345#M761674</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Date is dual field... which looks like a date, but has an underlying numeric value to it... when you were using Date() function to display hh:mm:ss... it was just DISPLAYING hh:mm:ss. Underlying value was still a date and time. Using Frac, we removed the date part and converted the date time to just time.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Does it make sense?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 30 Jul 2018 13:57:33 GMT</pubDate>
    <dc:creator>sunny_talwar</dc:creator>
    <dc:date>2018-07-30T13:57:33Z</dc:date>
    <item>
      <title>Condition on Date in Script</title>
      <link>https://community.qlik.com/t5/QlikView/Condition-on-Date-in-Script/m-p/139342#M761671</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;I have excel as source data. We have a field called Start Time. Format is like below:&lt;/P&gt;&lt;P&gt;&lt;IMG alt="" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/209277_pastedImage_0.png" style="max-width: 1200px; max-height: 900px;" /&gt;&lt;/P&gt;&lt;P&gt;Now I need to create a new field called SupportZone. The condition would be like below:&lt;/P&gt;&lt;P&gt;if time in between 10:00:00 and 22:00:01, then US support else India Support.&lt;/P&gt;&lt;P&gt;My script like below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;/TD&gt;&lt;TD&gt;if(Date([Start Time],'hh:mm:ss') &amp;gt;= '10:00:00' or Date([Start Time],'hh:mm:ss') &amp;lt; '22:00:01', 'US Support',&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&lt;/TD&gt;&lt;TD&gt;'India Support') as SupportZone,&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is not working properly. All records are coming under US Support.&lt;/P&gt;&lt;P&gt;Could any one please guide me.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sarif&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Condition-on-Date-in-Script/m-p/139342#M761671</guid>
      <dc:creator>mhmmd_srf</dc:creator>
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: Condition on Date in Script</title>
      <link>https://community.qlik.com/t5/QlikView/Condition-on-Date-in-Script/m-p/139343#M761672</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If(Frac([Start Time]) &amp;gt;= MakeTime(10) and Frac([Start Time]) &amp;lt; MakeTime(22, 0, 1), 'US Support', 'India Support') as SupportZone&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 30 Jul 2018 13:40:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Condition-on-Date-in-Script/m-p/139343#M761672</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2018-07-30T13:40:46Z</dc:date>
    </item>
    <item>
      <title>Re: Condition on Date in Script</title>
      <link>https://community.qlik.com/t5/QlikView/Condition-on-Date-in-Script/m-p/139344#M761673</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Looks like it is working. But I am bit curious how Frac is working on Date. I thought it works only in Number.&lt;/P&gt;&lt;P&gt;Can you please help me to understand.&lt;/P&gt;&lt;P&gt;If you have a good doc on this. Please share.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sarif&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 30 Jul 2018 13:50:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Condition-on-Date-in-Script/m-p/139344#M761673</guid>
      <dc:creator>mhmmd_srf</dc:creator>
      <dc:date>2018-07-30T13:50:25Z</dc:date>
    </item>
    <item>
      <title>Re: Condition on Date in Script</title>
      <link>https://community.qlik.com/t5/QlikView/Condition-on-Date-in-Script/m-p/139345#M761674</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Date is dual field... which looks like a date, but has an underlying numeric value to it... when you were using Date() function to display hh:mm:ss... it was just DISPLAYING hh:mm:ss. Underlying value was still a date and time. Using Frac, we removed the date part and converted the date time to just time.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Does it make sense?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 30 Jul 2018 13:57:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Condition-on-Date-in-Script/m-p/139345#M761674</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2018-07-30T13:57:33Z</dc:date>
    </item>
  </channel>
</rss>

