<?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 Scripterrorcount doesn’t see an error when data loading from PostgreSQL is broken in Connectivity &amp; Data Prep</title>
    <link>https://community.qlik.com/t5/Connectivity-Data-Prep/Scripterrorcount-doesn-t-see-an-error-when-data-loading-from/m-p/1519643#M3726</link>
    <description>&lt;P&gt;Good day!&lt;BR /&gt;Faced the problem of the following content:&lt;BR /&gt;I set up an incremental load from the Postgre database and everything works, but sometimes the data is not updated. I found out that at some point either the connection is broken, or the application simply does not connect to the database. However, the scriptorrorcount does not see the error.&amp;nbsp;As a result, the variable LastExecTime is updated and a hole appears in the data. Tell me how to be in this situation?&amp;nbsp;Thank you in advance.&lt;/P&gt;&lt;P&gt;Sample of script:&lt;/P&gt;&lt;P&gt;Let ThisExecTime = Timestamp(Now( ),'YYYY-MM-DD hh:mm:ss');&lt;BR /&gt;LIB CONNECT TO 'PostgreSQL';&lt;/P&gt;&lt;P&gt;TestQVD:&lt;/P&gt;&lt;P&gt;Load uid, some data,updateddate;&lt;BR /&gt;SQL Select&amp;nbsp;&lt;SPAN&gt;uid, some data,updateddate from data_table&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;where updateddate between&amp;nbsp;'$(LastExecTime ) 'and&amp;nbsp;'$(ThisExecTime&amp;nbsp;)';&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Concatenate LOAD&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;uid, some data,updateddate&lt;BR /&gt;FROM [lib://qlik/TestQvd.qvd]&lt;BR /&gt;(qvd)&lt;BR /&gt;where&amp;nbsp;not exists (uid);&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;inner join SQL&amp;nbsp;Select&amp;nbsp;uid from&amp;nbsp;data_table;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;If scripterrorcount = 0 then&lt;BR /&gt;store TestQVD into 'lib://qlik/TestQvd.qvd';&lt;BR /&gt;Let LastExecTime = ThisExecTime;&lt;BR /&gt;End If;&lt;BR /&gt;Drop table TestQVD;&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Wed, 12 Dec 2018 08:48:07 GMT</pubDate>
    <dc:creator>Ilya_Bobrov</dc:creator>
    <dc:date>2018-12-12T08:48:07Z</dc:date>
    <item>
      <title>Scripterrorcount doesn’t see an error when data loading from PostgreSQL is broken</title>
      <link>https://community.qlik.com/t5/Connectivity-Data-Prep/Scripterrorcount-doesn-t-see-an-error-when-data-loading-from/m-p/1519643#M3726</link>
      <description>&lt;P&gt;Good day!&lt;BR /&gt;Faced the problem of the following content:&lt;BR /&gt;I set up an incremental load from the Postgre database and everything works, but sometimes the data is not updated. I found out that at some point either the connection is broken, or the application simply does not connect to the database. However, the scriptorrorcount does not see the error.&amp;nbsp;As a result, the variable LastExecTime is updated and a hole appears in the data. Tell me how to be in this situation?&amp;nbsp;Thank you in advance.&lt;/P&gt;&lt;P&gt;Sample of script:&lt;/P&gt;&lt;P&gt;Let ThisExecTime = Timestamp(Now( ),'YYYY-MM-DD hh:mm:ss');&lt;BR /&gt;LIB CONNECT TO 'PostgreSQL';&lt;/P&gt;&lt;P&gt;TestQVD:&lt;/P&gt;&lt;P&gt;Load uid, some data,updateddate;&lt;BR /&gt;SQL Select&amp;nbsp;&lt;SPAN&gt;uid, some data,updateddate from data_table&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;where updateddate between&amp;nbsp;'$(LastExecTime ) 'and&amp;nbsp;'$(ThisExecTime&amp;nbsp;)';&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Concatenate LOAD&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;uid, some data,updateddate&lt;BR /&gt;FROM [lib://qlik/TestQvd.qvd]&lt;BR /&gt;(qvd)&lt;BR /&gt;where&amp;nbsp;not exists (uid);&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;inner join SQL&amp;nbsp;Select&amp;nbsp;uid from&amp;nbsp;data_table;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;If scripterrorcount = 0 then&lt;BR /&gt;store TestQVD into 'lib://qlik/TestQvd.qvd';&lt;BR /&gt;Let LastExecTime = ThisExecTime;&lt;BR /&gt;End If;&lt;BR /&gt;Drop table TestQVD;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 12 Dec 2018 08:48:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Connectivity-Data-Prep/Scripterrorcount-doesn-t-see-an-error-when-data-loading-from/m-p/1519643#M3726</guid>
      <dc:creator>Ilya_Bobrov</dc:creator>
      <dc:date>2018-12-12T08:48:07Z</dc:date>
    </item>
  </channel>
</rss>

