<?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: SQL select data with date filter in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/SQL-select-data-with-date-filter/m-p/718560#M1074401</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you, IsrarKhan for your responce, but nothing worked &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I helped myself with this SQL statement, which after all worked:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SQL SELECT ..., DATUMOBDOBI as Obdobie, ...&lt;/P&gt;&lt;P&gt;FROM "rsv2_stav".dbo."qryDatovySklad_QlikView"&lt;/P&gt;&lt;P&gt;WHERE DATUMOBDOBI &amp;gt; (SELECT max(UZAVRENEOBDOBI)&lt;/P&gt;&lt;P&gt;FROM "rsv2_stav".dbo."qryUzavreteObdobie");&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you very much for your time &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Duski&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 06 Aug 2014 06:31:20 GMT</pubDate>
    <dc:creator />
    <dc:date>2014-08-06T06:31:20Z</dc:date>
    <item>
      <title>SQL select data with date filter</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-select-data-with-date-filter/m-p/718555#M1074395</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Hi, everybody.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;I have a QV project with data import from MS SQL via script.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;I use the SQL statement for data import and I'd like to filter the date-field DATUMOBDOBI: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SQL SELECT ...., DATUMOBDOBI, ....&lt;/P&gt;&lt;P&gt;FROM "rsv2_stav".dbo."qryDatovySklad_QlikView"&lt;/P&gt;&lt;P&gt;Where DATUMOBDOBI &amp;gt; vUzavreneObdobi;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;vUzavreneObdobi is date-variable.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;Values / Formats of DATUMOBDOBI and vUzavreneObdobi look like this:&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;&lt;IMG alt="Snap_2014.08.05 17.09.54_003.jpg" class="jive-image" src="/legacyfs/online/63742_Snap_2014.08.05 17.09.54_003.jpg" /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;I have tried all possible syntax combinations (one of them see below), &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;but I receive an error.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;IMG alt="Snap_2014.08.05 17.16.22_004.jpg" class="jive-image" src="/legacyfs/online/63755_Snap_2014.08.05 17.16.22_004.jpg" style="width: 620px; height: 216px;" /&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Please help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Thanx in advance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Duski&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Aug 2014 15:18:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-select-data-with-date-filter/m-p/718555#M1074395</guid>
      <dc:creator />
      <dc:date>2014-08-05T15:18:26Z</dc:date>
    </item>
    <item>
      <title>Re: SQL select data with date filter</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-select-data-with-date-filter/m-p/718556#M1074396</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;You are trying to use Qlikview Syntax in SQL Query.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Instead of try normal SQL Query;&lt;/P&gt;&lt;P&gt;Then Use Resident load and use Where clause which you are trying.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Aug 2014 15:22:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-select-data-with-date-filter/m-p/718556#M1074396</guid>
      <dc:creator>PrashantSangle</dc:creator>
      <dc:date>2014-08-05T15:22:56Z</dc:date>
    </item>
    <item>
      <title>Re: SQL select data with date filter</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-select-data-with-date-filter/m-p/718557#M1074397</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;Try like this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;test:&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;SQL SELECT ...., DATUMOBDOBI, ....&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;FROM "rsv2_stav".dbo."qryDatovySklad_QlikView"&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Where DATUMOBDOBI &amp;gt; vUzavreneObdobi;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Final_test:&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;load * &lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;resident test&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;where date(date#(&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;DATUMOBDOBI,'DD.MM.YYYY')&amp;gt;Date(41791) &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Drop table test;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Regards,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Aug 2014 15:27:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-select-data-with-date-filter/m-p/718557#M1074397</guid>
      <dc:creator>PrashantSangle</dc:creator>
      <dc:date>2014-08-05T15:27:49Z</dc:date>
    </item>
    <item>
      <title>Re: SQL select data with date filter</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-select-data-with-date-filter/m-p/718558#M1074398</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Because one side you have Number and other side datetime, thats y your getting error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you need to convert Number to date, like &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Where DATUMOBDOBI &amp;gt; Date(vUzavreneObdobi);&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;and can you show me where you are declaring and initializing &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;vUzavreneObdobi.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;OR Initialize your variable like Date(YourDateField), than in the where clause you dont need to change anything.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Secondly you can convert your Date to number like,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;try like Num(&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;DATUMOBDOBI) &amp;gt; vUzavreneObdobi;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hope it helps&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Aug 2014 15:46:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-select-data-with-date-filter/m-p/718558#M1074398</guid>
      <dc:creator>israrkhan</dc:creator>
      <dc:date>2014-08-05T15:46:31Z</dc:date>
    </item>
    <item>
      <title>Re: SQL select data with date filter</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-select-data-with-date-filter/m-p/718559#M1074400</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you, max dreamer for your responce, but nothing worked &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I helped myself with this SQL statement, which after all worked:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SQL SELECT ..., DATUMOBDOBI as Obdobie, ...&lt;/P&gt;&lt;P&gt;FROM "rsv2_stav".dbo."qryDatovySklad_QlikView"&lt;/P&gt;&lt;P&gt;WHERE DATUMOBDOBI &amp;gt; (SELECT max(UZAVRENEOBDOBI)&lt;/P&gt;&lt;P&gt;FROM "rsv2_stav".dbo."qryUzavreteObdobie");&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you very much for your time &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Duski&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Aug 2014 06:30:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-select-data-with-date-filter/m-p/718559#M1074400</guid>
      <dc:creator />
      <dc:date>2014-08-06T06:30:55Z</dc:date>
    </item>
    <item>
      <title>Re: SQL select data with date filter</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-select-data-with-date-filter/m-p/718560#M1074401</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you, IsrarKhan for your responce, but nothing worked &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I helped myself with this SQL statement, which after all worked:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SQL SELECT ..., DATUMOBDOBI as Obdobie, ...&lt;/P&gt;&lt;P&gt;FROM "rsv2_stav".dbo."qryDatovySklad_QlikView"&lt;/P&gt;&lt;P&gt;WHERE DATUMOBDOBI &amp;gt; (SELECT max(UZAVRENEOBDOBI)&lt;/P&gt;&lt;P&gt;FROM "rsv2_stav".dbo."qryUzavreteObdobie");&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you very much for your time &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Duski&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Aug 2014 06:31:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-select-data-with-date-filter/m-p/718560#M1074401</guid>
      <dc:creator />
      <dc:date>2014-08-06T06:31:20Z</dc:date>
    </item>
  </channel>
</rss>

