<?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 Filtering on Date in Data Quality</title>
    <link>https://community.qlik.com/t5/Data-Quality/Filtering-on-Date/m-p/2506023#M4130</link>
    <description>&lt;P&gt;Hi,&lt;BR /&gt;&lt;BR /&gt;I'm new to Qlik and looking for some help/advice on how to filter some data.&lt;/P&gt;
&lt;P&gt;I have a read only connection into a PostgreSQL database. I have a table containing all orders since the company started. I essentially want to filter the data by date so that I only get the results back for the last 5 years.&lt;/P&gt;
&lt;P&gt;I've tried this but keep getting an error&lt;/P&gt;
&lt;P&gt;Where Date(Date#(order_date,'D-M-YYYY')) &amp;gt; '12-31-2020' but keep getting an error.&lt;/P&gt;
&lt;P&gt;Any help or pointers would be appreciated.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sat, 15 Feb 2025 12:22:01 GMT</pubDate>
    <dc:creator>SteveMcCabe</dc:creator>
    <dc:date>2025-02-15T12:22:01Z</dc:date>
    <item>
      <title>Filtering on Date</title>
      <link>https://community.qlik.com/t5/Data-Quality/Filtering-on-Date/m-p/2506023#M4130</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;&lt;BR /&gt;I'm new to Qlik and looking for some help/advice on how to filter some data.&lt;/P&gt;
&lt;P&gt;I have a read only connection into a PostgreSQL database. I have a table containing all orders since the company started. I essentially want to filter the data by date so that I only get the results back for the last 5 years.&lt;/P&gt;
&lt;P&gt;I've tried this but keep getting an error&lt;/P&gt;
&lt;P&gt;Where Date(Date#(order_date,'D-M-YYYY')) &amp;gt; '12-31-2020' but keep getting an error.&lt;/P&gt;
&lt;P&gt;Any help or pointers would be appreciated.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 15 Feb 2025 12:22:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Data-Quality/Filtering-on-Date/m-p/2506023#M4130</guid>
      <dc:creator>SteveMcCabe</dc:creator>
      <dc:date>2025-02-15T12:22:01Z</dc:date>
    </item>
    <item>
      <title>Re: Filtering on Date</title>
      <link>https://community.qlik.com/t5/Data-Quality/Filtering-on-Date/m-p/2506030#M4131</link>
      <description>&lt;P&gt;Hi Steve,&lt;/P&gt;
&lt;P&gt;I believe you get an error because you are trying to use Qlik functions, like Date#(), in a SQL statement. Instead, try to use PostgreSQL functions, or simply compare date fields without applying any functions.&lt;/P&gt;
&lt;P&gt;By default, I believe PostgreSQL dates are stored as 'YYYY-MM-DD'. If this is how your dates are stored, I'd try something like this:&lt;/P&gt;
&lt;P&gt;WHERE order_date &amp;gt; '2020-12-31'&lt;/P&gt;
&lt;P&gt;If your dates are stored differently, then use PostgreSQL date functions to bring the dates to YYYY-MM-DD format, in order to make them comparable as strings.&lt;/P&gt;
&lt;P&gt;Hopefully this helps,&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 15 Feb 2025 19:47:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Data-Quality/Filtering-on-Date/m-p/2506030#M4131</guid>
      <dc:creator>Oleg_Troyansky</dc:creator>
      <dc:date>2025-02-15T19:47:14Z</dc:date>
    </item>
  </channel>
</rss>

