<?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: like operator only valid on string field in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/like-operator-only-valid-on-string-field/m-p/576#M119</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Petter - I was querying a Salesforce database so I had to adhere to the SOQL guidelines. Wound up being CreatedDate &amp;gt; &lt;SPAN style="font-family: DSCDefaultFontRegular; font-size: 14px;"&gt;2017-01-01T00:00:00Z&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 14 Jan 2018 19:37:00 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2018-01-14T19:37:00Z</dc:date>
    <item>
      <title>like operator only valid on string field</title>
      <link>https://community.qlik.com/t5/QlikView/like-operator-only-valid-on-string-field/m-p/573#M116</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;trying to limit the extract of data in a Qlik Sense app on an ActivityDate field but I am getting the error "like operator only valid on string field" .. Example of syntax is below&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Load&lt;/P&gt;&lt;P&gt;Id,&lt;/P&gt;&lt;P&gt;ActivityDate,&lt;/P&gt;&lt;P&gt;Subject ;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT&lt;/P&gt;&lt;P&gt;Id,&lt;/P&gt;&lt;P&gt;ActivityDate,&lt;/P&gt;&lt;P&gt;Subject&lt;/P&gt;&lt;P&gt;FROM Task&lt;/P&gt;&lt;P&gt;WHERE ActivityDate LIKE '*2017*' OR ActivityDate LIKE '*2018*'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help is appreciated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- dave&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 14 Jan 2018 19:11:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/like-operator-only-valid-on-string-field/m-p/573#M116</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-01-14T19:11:02Z</dc:date>
    </item>
    <item>
      <title>Re: like operator only valid on string field</title>
      <link>https://community.qlik.com/t5/QlikView/like-operator-only-valid-on-string-field/m-p/574#M117</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;When you are writing a SQL SELECT the LIKE operator is dependent on the syntax of the source you are using. It is not following syntax or rules of Qlik Sense.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 14 Jan 2018 19:26:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/like-operator-only-valid-on-string-field/m-p/574#M117</guid>
      <dc:creator>petter</dc:creator>
      <dc:date>2018-01-14T19:26:11Z</dc:date>
    </item>
    <item>
      <title>Re: like operator only valid on string field</title>
      <link>https://community.qlik.com/t5/QlikView/like-operator-only-valid-on-string-field/m-p/575#M118</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I presume the select is against a database and the issue is within the sql and not a Qlik Statement.&amp;nbsp; &lt;/P&gt;&lt;UL&gt;&lt;LI&gt;What database is it ?&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Does your database field &lt;SPAN style="color: #000000; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;EM&gt;ActivityDate &lt;/EM&gt;&lt;/SPAN&gt;&lt;EM&gt; &lt;/EM&gt;have a data type of date as opposed to a string ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you are using Oracle then maybe something like this could suffice :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;EM&gt;where extract ( year from &lt;/EM&gt;&lt;SPAN style="color: #000000; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;EM&gt;ActivityDate&amp;nbsp; ) between&amp;nbsp; 2017 and 2018&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 14 Jan 2018 19:31:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/like-operator-only-valid-on-string-field/m-p/575#M118</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-01-14T19:31:33Z</dc:date>
    </item>
    <item>
      <title>Re: like operator only valid on string field</title>
      <link>https://community.qlik.com/t5/QlikView/like-operator-only-valid-on-string-field/m-p/576#M119</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Petter - I was querying a Salesforce database so I had to adhere to the SOQL guidelines. Wound up being CreatedDate &amp;gt; &lt;SPAN style="font-family: DSCDefaultFontRegular; font-size: 14px;"&gt;2017-01-01T00:00:00Z&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 14 Jan 2018 19:37:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/like-operator-only-valid-on-string-field/m-p/576#M119</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-01-14T19:37:00Z</dc:date>
    </item>
    <item>
      <title>Re: like operator only valid on string field</title>
      <link>https://community.qlik.com/t5/QlikView/like-operator-only-valid-on-string-field/m-p/577#M120</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In all the databases and lanugages I have used LIKE pattern matching is based on text or character type of information. You could always convert ActivityDate if it is date into a character column. Usually it makes much more sense to do a:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;WHERE&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; ActivityDate &lt;STRONG&gt;BETWEEN &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CAST('2017-01-01T00:00:00' AS DATETIME) &lt;STRONG&gt;AND &lt;/STRONG&gt;CAST('2018-12-31T23:59:59' AS DATETIME)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 14 Jan 2018 19:50:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/like-operator-only-valid-on-string-field/m-p/577#M120</guid>
      <dc:creator>petter</dc:creator>
      <dc:date>2018-01-14T19:50:32Z</dc:date>
    </item>
  </channel>
</rss>

