<?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 NPrinting Filter on Date that uses auto Calendar date fields in Qlik NPrinting</title>
    <link>https://community.qlik.com/t5/Qlik-NPrinting/NPrinting-Filter-on-Date-that-uses-auto-Calendar-date-fields/m-p/1783608#M31236</link>
    <description>&lt;P&gt;I am experimenting with advanced search filters.&amp;nbsp; I want to filter the Beginners tutorial app to display the year 2013 and the months that begin with J&amp;nbsp; (Jan, Jun, Jul).&amp;nbsp; &amp;nbsp;In the application there is one field &lt;STRONG&gt;Date&lt;/STRONG&gt;&amp;nbsp;to select for filtering the date - the date has&amp;nbsp; autoCalendar fields - Date.autoCalendar.Date, Date.autoCalendar.Year,&amp;nbsp;Date.autoCalendar.Month .&amp;nbsp; How do I code a filter for the date parts?&amp;nbsp; I was able to create a filter on the year 2013 by putting this expression in the Advanced Search value in nprinting&amp;nbsp; &amp;nbsp;&amp;gt;12/31/2012&amp;lt;1/1/2014.&amp;nbsp; I am able to make selections in the Beginner's Tutorial app for the date parts but what appears in the selections are the date part field names and I tried using those in the nprinting filter but I can't get them to work.&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="mjht_0-1613597541880.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/49310iD345E44492D8AFC7/image-size/medium?v=v2&amp;amp;px=400" role="button" title="mjht_0-1613597541880.png" alt="mjht_0-1613597541880.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 17 Feb 2021 21:35:09 GMT</pubDate>
    <dc:creator>mjht</dc:creator>
    <dc:date>2021-02-17T21:35:09Z</dc:date>
    <item>
      <title>NPrinting Filter on Date that uses auto Calendar date fields</title>
      <link>https://community.qlik.com/t5/Qlik-NPrinting/NPrinting-Filter-on-Date-that-uses-auto-Calendar-date-fields/m-p/1783608#M31236</link>
      <description>&lt;P&gt;I am experimenting with advanced search filters.&amp;nbsp; I want to filter the Beginners tutorial app to display the year 2013 and the months that begin with J&amp;nbsp; (Jan, Jun, Jul).&amp;nbsp; &amp;nbsp;In the application there is one field &lt;STRONG&gt;Date&lt;/STRONG&gt;&amp;nbsp;to select for filtering the date - the date has&amp;nbsp; autoCalendar fields - Date.autoCalendar.Date, Date.autoCalendar.Year,&amp;nbsp;Date.autoCalendar.Month .&amp;nbsp; How do I code a filter for the date parts?&amp;nbsp; I was able to create a filter on the year 2013 by putting this expression in the Advanced Search value in nprinting&amp;nbsp; &amp;nbsp;&amp;gt;12/31/2012&amp;lt;1/1/2014.&amp;nbsp; I am able to make selections in the Beginner's Tutorial app for the date parts but what appears in the selections are the date part field names and I tried using those in the nprinting filter but I can't get them to work.&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="mjht_0-1613597541880.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/49310iD345E44492D8AFC7/image-size/medium?v=v2&amp;amp;px=400" role="button" title="mjht_0-1613597541880.png" alt="mjht_0-1613597541880.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 17 Feb 2021 21:35:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Qlik-NPrinting/NPrinting-Filter-on-Date-that-uses-auto-Calendar-date-fields/m-p/1783608#M31236</guid>
      <dc:creator>mjht</dc:creator>
      <dc:date>2021-02-17T21:35:09Z</dc:date>
    </item>
    <item>
      <title>Re: NPrinting Filter on Date that uses auto Calendar date fields</title>
      <link>https://community.qlik.com/t5/Qlik-NPrinting/NPrinting-Filter-on-Date-that-uses-auto-Calendar-date-fields/m-p/1783629#M31238</link>
      <description>&lt;P&gt;First thing first...&amp;nbsp;&lt;/P&gt;&lt;P&gt;Do you understand what those fields are, how they are created and what values they hold? Yes - VALUES!!!&lt;/P&gt;&lt;P&gt;Have a look at this part of autocalendar script :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="cpp"&gt;[autoCalendar]: 
  DECLARE FIELD DEFINITION Tagged ('$date')
FIELDS
  Dual(Year($1), YearStart($1)) AS [Year] Tagged ('$axis', '$year'),
  Month($1) AS [Month] Tagged ('$month', '$cyclic'),
  Dual(Year($1)&amp;amp;'-'&amp;amp;Month($1), monthstart($1)) AS [YearMonth] Tagged ('$axis', '$yearmonth', '$qualified'),
  Dual(Month($1), monthstart($1)) AS [_YearMonth] Tagged ('$axis', '$yearmonth', '$simplified', '$hidden'),
  Dual('W'&amp;amp;Num(Week($1),00), Num(Week($1),00)) AS [Week] Tagged ('$weeknumber', '$cyclic'),
  Date(Floor($1)) AS [Date] Tagged ('$axis', '$date', '$qualified');

DERIVE FIELDS FROM FIELDS [event_time] USING [autoCalendar] ;&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can notice that all values from there are actually derived from 1 date field, in my case it is [event_time] field. AutoCalendar fields are not present in data model like regural fields so you cannot create filter in NPrinting on for example YearMonth field.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Instead you need to create advanced search expressions which will filter event_dates to those values..&lt;/P&gt;&lt;P&gt;for example:&lt;/P&gt;&lt;P&gt;=count({&amp;lt;[event_time.autoCalendar.Month]={'Jan.','Jun.','Jul.'}&amp;gt;}event_time)&amp;gt;0&lt;/P&gt;&lt;P&gt;Be aware of datatypes you are trying to filter as well as syntax. More about that you can read here:&lt;/P&gt;&lt;P&gt;&lt;A href="https://nprintingadventures.com/2019/06/26/nprinting-filters-part-3-advanced-search/" target="_blank" rel="noopener"&gt;https://nprintingadventures.com/2019/06/26/nprinting-filters-part-3-advanced-search/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://nprintingadventures.com/2019/02/15/the-pitfalls-of-nprinting-filters-part-1-dates-and-duals/" target="_blank" rel="noopener"&gt;https://nprintingadventures.com/2019/02/15/the-pitfalls-of-nprinting-filters-part-1-dates-and-duals/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://nprintingadventures.com/2019/02/15/the-pitfalls-of-nprinting-filters-part-1-dates-and-duals/" target="_blank" rel="noopener"&gt;https://nprintingadventures.com&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;see below:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="1.png" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/49317iB805282F001DE50D/image-size/large?v=v2&amp;amp;px=999" role="button" title="1.png" alt="1.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="2021-02-18_09-58-19 (2).gif" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/49315iF43F6EE990BAD134/image-size/large?v=v2&amp;amp;px=999" role="button" title="2021-02-18_09-58-19 (2).gif" alt="2021-02-18_09-58-19 (2).gif" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 17 Feb 2021 23:09:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Qlik-NPrinting/NPrinting-Filter-on-Date-that-uses-auto-Calendar-date-fields/m-p/1783629#M31238</guid>
      <dc:creator>Lech_Miszkiewicz</dc:creator>
      <dc:date>2021-02-17T23:09:28Z</dc:date>
    </item>
    <item>
      <title>Re: NPrinting Filter on Date that uses auto Calendar date fields</title>
      <link>https://community.qlik.com/t5/Qlik-NPrinting/NPrinting-Filter-on-Date-that-uses-auto-Calendar-date-fields/m-p/1783909#M31249</link>
      <description>&lt;P&gt;Thank you for your reply -&amp;nbsp; yes I do understand what the fields are and the values they hold.&amp;nbsp; I was not clear on the syntax needed in the advanced filter to address them in nprinting.&amp;nbsp; You have provided the syntax I was looking for and I will give it a try and report back.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Update ---&amp;nbsp; worked perfectly!&amp;nbsp; I was just missing the syntax needed.&amp;nbsp; The expression in Advanced Search did it.&lt;/P&gt;&lt;P&gt;=count({&amp;lt;[Date.autoCalendar.Month]={'Jan','Jun','Jul'},[Date.autoCalendar.Year]={2013}&amp;gt;}Date) &amp;gt; 0&lt;/P&gt;&lt;P&gt;Thank you for the quick reply, Lech !&lt;/P&gt;</description>
      <pubDate>Thu, 18 Feb 2021 16:11:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Qlik-NPrinting/NPrinting-Filter-on-Date-that-uses-auto-Calendar-date-fields/m-p/1783909#M31249</guid>
      <dc:creator>mjht</dc:creator>
      <dc:date>2021-02-18T16:11:26Z</dc:date>
    </item>
    <item>
      <title>Re: NPrinting Filter on Date that uses auto Calendar date fields</title>
      <link>https://community.qlik.com/t5/Qlik-NPrinting/NPrinting-Filter-on-Date-that-uses-auto-Calendar-date-fields/m-p/1783986#M31253</link>
      <description>&lt;P&gt;Awesome. Cheers!&lt;/P&gt;</description>
      <pubDate>Thu, 18 Feb 2021 20:18:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Qlik-NPrinting/NPrinting-Filter-on-Date-that-uses-auto-Calendar-date-fields/m-p/1783986#M31253</guid>
      <dc:creator>Lech_Miszkiewicz</dc:creator>
      <dc:date>2021-02-18T20:18:00Z</dc:date>
    </item>
  </channel>
</rss>

