<?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 General in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/General/m-p/1355834#M828517</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;Can any one explain me how this is working i mean the workflow of this statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;"If(Year2Date(Date, 0, 1, Today()), 1, 0) As YTDFlag,"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am new to qlikview&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2020-11-25T16:16:04Z</dc:date>
    <item>
      <title>General</title>
      <link>https://community.qlik.com/t5/QlikView/General/m-p/1355834#M828517</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;Can any one explain me how this is working i mean the workflow of this statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;"If(Year2Date(Date, 0, 1, Today()), 1, 0) As YTDFlag,"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am new to qlikview&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/General/m-p/1355834#M828517</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: General</title>
      <link>https://community.qlik.com/t5/QlikView/General/m-p/1355835#M828518</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Looking at QlikView help, I didn't find Year2Date(), but YearToDate() function. But the funny thing is that although the syntax editor doesn't understand Year2Date, it still resolves to the same result as YearToDate().&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Anyways, coming back to the expression (&lt;A href="http://help.qlik.com/en-US/qlikview/12.0/Subsystems/Client/Content/Scripting/DateAndTimeFunctions/yeartodate.htm" title="http://help.qlik.com/en-US/qlikview/12.0/Subsystems/Client/Content/Scripting/DateAndTimeFunctions/yeartodate.htm"&gt;yeartodate ‒ QlikView&lt;/A&gt;), helps show this&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="168052" alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/168052_Capture.PNG" style="height: 130px; width: 620px;" /&gt;&lt;/P&gt;&lt;P&gt;So, this in your script will work like this&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;If(Year2Date(Date, 0, 1, Today()), 1, 0) As YTDFlag&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1) Date -&amp;gt; This is the Date field you are trying to figure out if it is in the YTD or not&lt;/P&gt;&lt;P&gt;2) 0 -&amp;gt; Year Offset... is this for the current year (0) or last year (-1). Right now you have it from the current year's YTD&lt;/P&gt;&lt;P&gt;3) 1 -&amp;gt; First month of the year. Do you have January as your 1st month (1) or April as the first month (4)&lt;/P&gt;&lt;P&gt;4) Today() -&amp;gt; What is the upper limit of the YTD. In your case you are trying to figure out YTD till today(). So in case you have data points for August 2017, they would not be part of your YTDFlag&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Does this make sense? The link I have shared have few example, do take some time to check them out.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best,&lt;BR /&gt;Sunny&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 25 Jun 2017 23:01:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/General/m-p/1355835#M828518</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-06-25T23:01:05Z</dc:date>
    </item>
  </channel>
</rss>

