<?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: Get max timestamp from table in load script in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637115#M47482</link>
    <description>&lt;P&gt;Yes, that's a normal function of Qlik.&lt;/P&gt;&lt;P&gt;If you load datas and the table schema (all fields) exists the datas are concatenated on the existing datas.&lt;/P&gt;&lt;P&gt;So you double the datas in the original table.&lt;/P&gt;&lt;P&gt;Statement&amp;nbsp;&lt;/P&gt;&lt;P&gt;load * resident table won't never work.&lt;/P&gt;&lt;P&gt;You have to add a field or&lt;/P&gt;&lt;P&gt;noconcatenate load * resident table&lt;/P&gt;</description>
    <pubDate>Fri, 18 Oct 2019 11:12:49 GMT</pubDate>
    <dc:creator>martinpohl</dc:creator>
    <dc:date>2019-10-18T11:12:49Z</dc:date>
    <item>
      <title>Get max timestamp from table in load script</title>
      <link>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637103#M47475</link>
      <description>&lt;P&gt;Hi all.&lt;/P&gt;&lt;P&gt;I'm trying to write my load script so that it loads only new entries from my BigQuery tables. To do this I want to declare a variable with the max timestamp of the Table I already have in Qlik and use it in a WHERE condition, but I'm having problems declaring such variable. Here's what I'm trying:&lt;/P&gt;&lt;P&gt;LOAD Max(timestamp) AS [MaxTimestamp] Resident table_main_test;&lt;BR /&gt;Let Max_date = Timestamp([MaxTimestamp]);&lt;/P&gt;&lt;P&gt;LIB CONNECT TO [Google_BigQuery_altran-vodafonept-cpe-qa];&lt;/P&gt;&lt;P&gt;[table_main_test]:&lt;/P&gt;&lt;P&gt;SELECT `timestamp`,&lt;BR /&gt;`cpe_cpeid`,&lt;BR /&gt;`cpe_metadata_accessid`,&lt;BR /&gt;`cpe_vendor_model_sw_version`,&lt;BR /&gt;`props_cpe_vendor`,&lt;BR /&gt;`props_cpe_model_name`,&lt;BR /&gt;`props_cpe_sw_version`,&lt;BR /&gt;`cpe_uptime`,&lt;BR /&gt;`cpe_reboots`,&lt;BR /&gt;`avg_cpu`,&lt;BR /&gt;`avg_ram`,&lt;BR /&gt;`max`&lt;BR /&gt;FROM KPI.`table_main_test`&lt;BR /&gt;WHERE `timestamp` &amp;gt; '$(Max_date)'&lt;BR /&gt;;&lt;/P&gt;&lt;P&gt;Concatenate LOAD * Resident table_main_test ;&lt;/P&gt;&lt;P&gt;It gives the following error:&amp;nbsp;&lt;/P&gt;&lt;DIV class="edc_error"&gt;Table 'table_main_test' not found.&lt;/DIV&gt;&lt;DIV class="edc_error"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="edc_error"&gt;But the table exists, so I'm not sure what's going on&lt;/DIV&gt;</description>
      <pubDate>Sat, 16 Nov 2024 19:51:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637103#M47475</guid>
      <dc:creator>tmdongacardoso</dc:creator>
      <dc:date>2024-11-16T19:51:56Z</dc:date>
    </item>
    <item>
      <title>Re: Get max timestamp from table in load script</title>
      <link>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637107#M47476</link>
      <description>&lt;P&gt;Where in the script are you using table_main_test? All I see is a reference to table_main&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="image.png" style="width: 542px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/21875i23D867F394253931/image-size/large?v=v2&amp;amp;px=999" role="button" title="image.png" alt="image.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 18 Oct 2019 11:04:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637107#M47476</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2019-10-18T11:04:11Z</dc:date>
    </item>
    <item>
      <title>Re: Get max timestamp from table in load script</title>
      <link>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637109#M47477</link>
      <description>&lt;P&gt;Did you checked that the table is existing in table viewer?&lt;/P&gt;&lt;P&gt;maybe an automatic concatenate has concatenate datas to another table?&lt;/P&gt;&lt;P&gt;so script:&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;table_main_test:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;nocontatenate load&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;</description>
      <pubDate>Fri, 18 Oct 2019 11:05:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637109#M47477</guid>
      <dc:creator>martinpohl</dc:creator>
      <dc:date>2019-10-18T11:05:47Z</dc:date>
    </item>
    <item>
      <title>Re: Get max timestamp from table in load script</title>
      <link>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637111#M47479</link>
      <description>&lt;P&gt;Yeah I miss wrote it when I was posting the question, it's table_main_test.&amp;nbsp; The problem is the same though&lt;/P&gt;</description>
      <pubDate>Fri, 18 Oct 2019 11:07:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637111#M47479</guid>
      <dc:creator>tmdongacardoso</dc:creator>
      <dc:date>2019-10-18T11:07:09Z</dc:date>
    </item>
    <item>
      <title>Re: Get max timestamp from table in load script</title>
      <link>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637113#M47480</link>
      <description>&lt;P&gt;Hm no, this is the only table I have in the app. The weird thing is, If I use the expression&amp;nbsp;&lt;/P&gt;&lt;P&gt;LOAD * RESIDENT table_main_test after the SQL query to get the table from BigQuery, the script recognizes the name table_main_test.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 18 Oct 2019 11:10:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637113#M47480</guid>
      <dc:creator>tmdongacardoso</dc:creator>
      <dc:date>2019-10-18T11:10:16Z</dc:date>
    </item>
    <item>
      <title>Re: Get max timestamp from table in load script</title>
      <link>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637114#M47481</link>
      <description>&lt;P&gt;but, your let-statement won't work&lt;/P&gt;&lt;P&gt;Use&lt;/P&gt;&lt;P&gt;let Max_date = peek('MaxTimestamp',0,');&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;</description>
      <pubDate>Fri, 18 Oct 2019 11:10:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637114#M47481</guid>
      <dc:creator>martinpohl</dc:creator>
      <dc:date>2019-10-18T11:10:37Z</dc:date>
    </item>
    <item>
      <title>Re: Get max timestamp from table in load script</title>
      <link>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637115#M47482</link>
      <description>&lt;P&gt;Yes, that's a normal function of Qlik.&lt;/P&gt;&lt;P&gt;If you load datas and the table schema (all fields) exists the datas are concatenated on the existing datas.&lt;/P&gt;&lt;P&gt;So you double the datas in the original table.&lt;/P&gt;&lt;P&gt;Statement&amp;nbsp;&lt;/P&gt;&lt;P&gt;load * resident table won't never work.&lt;/P&gt;&lt;P&gt;You have to add a field or&lt;/P&gt;&lt;P&gt;noconcatenate load * resident table&lt;/P&gt;</description>
      <pubDate>Fri, 18 Oct 2019 11:12:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637115#M47482</guid>
      <dc:creator>martinpohl</dc:creator>
      <dc:date>2019-10-18T11:12:49Z</dc:date>
    </item>
    <item>
      <title>Re: Get max timestamp from table in load script</title>
      <link>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637159#M47489</link>
      <description>&lt;P&gt;I can concatenate the results of the query with my table by doing:&lt;/P&gt;&lt;P&gt;CONCATENATE LOAD * RESIDENT table_main_test.&lt;/P&gt;&lt;P&gt;However, before doing that I want to get the highest timestamp value in my current table, that's where I am having problems and using NoConcatenate does not help.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 18 Oct 2019 12:30:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Get-max-timestamp-from-table-in-load-script/m-p/1637159#M47489</guid>
      <dc:creator>tmdongacardoso</dc:creator>
      <dc:date>2019-10-18T12:30:33Z</dc:date>
    </item>
  </channel>
</rss>

