<?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 SQL statements is not working on load script editor in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/SQL-statements-is-not-working-on-load-script-editor/m-p/83060#M5511</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello everybody&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am trying to upload a sql statement in the load script editor using Qlik sense Desktop. In my local machine using mysql Workbench the query is working. I'm getting always the following error.&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="204820" alt="Error message.PNG" class="jive-image image-1" src="/legacyfs/online/204820_Error message.PNG" style="height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have also checked the time format settings&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="204821" alt="Format.PNG" class="jive-image image-2" src="https://community.qlik.com/legacyfs/online/204821_Format.PNG" style="width: 620px; height: 241px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The code i am using:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; SEC_TO_TIME(SUM(UNIX_TIMESTAMP(r.start_date) - UNIX_TIMESTAMP(s.end_date)) / (COUNT(CURDATE()))) AS Average,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; DATE_FORMAT(start_date, '%Y-%m-%d') AS DAY&lt;/P&gt;&lt;P&gt;FROM&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; db.table1 r,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; db.table2 s&lt;/P&gt;&lt;P&gt;WHERE&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; r.id = s.id&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AND TIMEDIFF(r.start_date, s.end_date) IS NOT NULL&lt;/P&gt;&lt;P&gt;GROUP BY day&lt;/P&gt;&lt;P&gt;ORDER BY start_date;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;start date and enddate are saved in datetimeformat. As you can see i'm groupping datetime value in a day value. I'm not sure if this is the probelm. If yes can anybody tell me how to fix this problem?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 11 Jun 2018 12:53:59 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2018-06-11T12:53:59Z</dc:date>
    <item>
      <title>SQL statements is not working on load script editor</title>
      <link>https://community.qlik.com/t5/App-Development/SQL-statements-is-not-working-on-load-script-editor/m-p/83060#M5511</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello everybody&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am trying to upload a sql statement in the load script editor using Qlik sense Desktop. In my local machine using mysql Workbench the query is working. I'm getting always the following error.&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="204820" alt="Error message.PNG" class="jive-image image-1" src="/legacyfs/online/204820_Error message.PNG" style="height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have also checked the time format settings&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="204821" alt="Format.PNG" class="jive-image image-2" src="https://community.qlik.com/legacyfs/online/204821_Format.PNG" style="width: 620px; height: 241px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The code i am using:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; SEC_TO_TIME(SUM(UNIX_TIMESTAMP(r.start_date) - UNIX_TIMESTAMP(s.end_date)) / (COUNT(CURDATE()))) AS Average,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; DATE_FORMAT(start_date, '%Y-%m-%d') AS DAY&lt;/P&gt;&lt;P&gt;FROM&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; db.table1 r,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; db.table2 s&lt;/P&gt;&lt;P&gt;WHERE&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; r.id = s.id&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AND TIMEDIFF(r.start_date, s.end_date) IS NOT NULL&lt;/P&gt;&lt;P&gt;GROUP BY day&lt;/P&gt;&lt;P&gt;ORDER BY start_date;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;start date and enddate are saved in datetimeformat. As you can see i'm groupping datetime value in a day value. I'm not sure if this is the probelm. If yes can anybody tell me how to fix this problem?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Jun 2018 12:53:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/SQL-statements-is-not-working-on-load-script-editor/m-p/83060#M5511</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-06-11T12:53:59Z</dc:date>
    </item>
  </channel>
</rss>

