<?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: Peek function  not catching any value from SQL select table while using rest connector script in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Peek-function-not-catching-any-value-from-SQL-select-table-while/m-p/2053318#M1223070</link>
    <description>&lt;P&gt;I'm stuck on the exact same thing at the moment, did you ever solve this?&lt;/P&gt;</description>
    <pubDate>Mon, 27 Mar 2023 04:27:51 GMT</pubDate>
    <dc:creator>André</dc:creator>
    <dc:date>2023-03-27T04:27:51Z</dc:date>
    <item>
      <title>Peek function  not catching any value from SQL select table while using rest connector script</title>
      <link>https://community.qlik.com/t5/QlikView/Peek-function-not-catching-any-value-from-SQL-select-table-while/m-p/1766008#M590905</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am using standard qlik script for Rest API token generation but while loading data I am facing an issue that peek variable not catching any value from a table.&lt;/P&gt;&lt;P&gt;LIB CONNECT TO 'next token';&lt;/P&gt;&lt;P&gt;Let sessionId='';&lt;BR /&gt;Set nextTokenParamName='';&lt;/P&gt;&lt;P&gt;Do&lt;BR /&gt;RestConnectorMasterTable:&lt;BR /&gt;SQL SELECT&lt;BR /&gt;"Token",&lt;BR /&gt;"__KEY_root",&lt;BR /&gt;(SELECT&lt;BR /&gt;"_id",&lt;BR /&gt;"city",&lt;BR /&gt;"pop",&lt;BR /&gt;"state",&lt;BR /&gt;"__KEY_Items",&lt;BR /&gt;"__FK_Items",&lt;BR /&gt;(SELECT&lt;BR /&gt;"@Value",&lt;BR /&gt;"__FK_loc"&lt;BR /&gt;FROM "loc" FK "__FK_loc" ArrayValueAlias "@Value")&lt;BR /&gt;FROM "Items" PK "__KEY_Items" FK "__FK_Items")&lt;BR /&gt;FROM JSON (wrap on) "root" PK "__KEY_root"&lt;BR /&gt;WITH CONNECTION(&lt;BR /&gt;QUERY "$(nextTokenParamName)" "$(sessionId)"&lt;BR /&gt;);&lt;/P&gt;&lt;P&gt;Set nextTokenParamName = 'Token';&lt;/P&gt;&lt;P&gt;let sessionId = peek('Token',-1,'RestConnectorMasterTable');&lt;/P&gt;&lt;P&gt;Trace 'The sessionId is: ' $(sessionId);&lt;/P&gt;&lt;P&gt;loop until $(sessionId) =''&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;so as per this code sessionid should catch the latest token value and pass it to further loop until the value becomes null.&lt;/P&gt;&lt;P&gt;but my peek function is not working with this SQL Select table.&lt;/P&gt;&lt;P&gt;please guide me as it is a very critical job failure.&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 17:45:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Peek-function-not-catching-any-value-from-SQL-select-table-while/m-p/1766008#M590905</guid>
      <dc:creator>qliklearnervir</dc:creator>
      <dc:date>2024-11-16T17:45:02Z</dc:date>
    </item>
    <item>
      <title>Re: Peek function  not catching any value from SQL select table while using rest connector script</title>
      <link>https://community.qlik.com/t5/QlikView/Peek-function-not-catching-any-value-from-SQL-select-table-while/m-p/2053318#M1223070</link>
      <description>&lt;P&gt;I'm stuck on the exact same thing at the moment, did you ever solve this?&lt;/P&gt;</description>
      <pubDate>Mon, 27 Mar 2023 04:27:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Peek-function-not-catching-any-value-from-SQL-select-table-while/m-p/2053318#M1223070</guid>
      <dc:creator>André</dc:creator>
      <dc:date>2023-03-27T04:27:51Z</dc:date>
    </item>
    <item>
      <title>Re: Peek function  not catching any value from SQL select table while using rest connector script</title>
      <link>https://community.qlik.com/t5/QlikView/Peek-function-not-catching-any-value-from-SQL-select-table-while/m-p/2053341#M1223071</link>
      <description>&lt;P&gt;I doubt that there is an issue with peek() else that the loop and/or the sql didn't work like expected and therefore nothing respectively the right content for the peek() exists. Therefore split the logic in parts without a loop and with fixed values instead of the variables and adding then the more complexity step by step.&lt;/P&gt;</description>
      <pubDate>Mon, 27 Mar 2023 05:53:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Peek-function-not-catching-any-value-from-SQL-select-table-while/m-p/2053341#M1223071</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2023-03-27T05:53:09Z</dc:date>
    </item>
  </channel>
</rss>

