<?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: REST Connector header query parameter in Connectivity &amp; Data Prep</title>
    <link>https://community.qlik.com/t5/Connectivity-Data-Prep/REST-Connector-header-query-parameter/m-p/1568666#M3824</link>
    <description>&lt;P&gt;I've tried all of them within the URL connection statement. However, it doesn't work. I managed to fix it by editing the URL with some query parameters inside of it, i.e.&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;https://opendata.cbs.nl/ODataApi/odata/83131NED/TypedDataSet?$filter=Bestedingscategorieen%20eq%20%27T001112%20%20%27&amp;amp;$skip=273&lt;/PRE&gt;&lt;P&gt;As of now I only fetch the category I want.&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 12 Apr 2019 09:13:56 GMT</pubDate>
    <dc:creator>klikgevoel</dc:creator>
    <dc:date>2019-04-12T09:13:56Z</dc:date>
    <item>
      <title>REST Connector header query parameter</title>
      <link>https://community.qlik.com/t5/Connectivity-Data-Prep/REST-Connector-header-query-parameter/m-p/1567539#M3816</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;I'm trying to fetch data from an URL, which works fine so far. However, I want to collect only data that is needed, and not the whole shabang. For that to work I want to collect the data that satisfies a certain condition within a header. I already tried it within the REST Connector settings table by defining the header name and parameter, but with no luck. My guess is that I need to define it within a variable and pass it into the URL query string. A sample of my code is given below.&lt;/P&gt;&lt;P&gt;The header is named: Bestedingscategorieen and the condition is:&amp;nbsp;T001112. So I only want to collect that data.&lt;/P&gt;&lt;PRE&gt;Main:
LET vTopNum 		= 9999;
LET vSkipNum 		= 0;
LET vCounterNum 	= 2;

LIB CONNECT TO 'CBS_CPI_CONNECTOR';

LET vTop 		= vTopNum;
LET vSkip 		= vSkipNum;
LET vCounter 	= vCounterNum;

DO WHILE vCounter &amp;gt; 1
RestConnectorMasterTable:
SQL SELECT 
	"__KEY_root",
	(SELECT 
		"ID",
		"Bestedingscategorieen",
		"Perioden",
		"CPI_1",
		"CPIAfgeleid_2",
		"JaarmutatieCPI_5",
		"JaarmutatieCPIAfgeleid_6",
		"__FK_value"
	FROM "value" FK "__FK_value")
FROM JSON (wrap on) "root" PK "__KEY_root"
WITH CONNECTION
		( Url 
			"https://opendata.cbs.nl/ODataApi/odata/83131NED/TypedDataSet?$top=$(vTop)&amp;amp;$skip=$(vSkip)"
            );


LET vCounter = NoOfRows('RestConnectorMasterTable');

  temp_cbs_load_table:
  LOAD
  *,
  'Reload' AS Source
  RESIDENT RestConnectorMasterTable;
  
  DROP TABLE RestConnectorMasterTable;

  TRACE 'Skip = '		$(vSkip) ;
  TRACE 'Counter =' 	$(vCounter);

  LET vSkip = $(vSkip) + $(vTop);

LOOP&lt;/PRE&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;</description>
      <pubDate>Thu, 23 Dec 2021 14:25:13 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Connectivity-Data-Prep/REST-Connector-header-query-parameter/m-p/1567539#M3816</guid>
      <dc:creator>klikgevoel</dc:creator>
      <dc:date>2021-12-23T14:25:13Z</dc:date>
    </item>
    <item>
      <title>Re: REST Connector header query parameter</title>
      <link>https://community.qlik.com/t5/Connectivity-Data-Prep/REST-Connector-header-query-parameter/m-p/1567903#M3817</link>
      <description>&lt;P&gt;Did you try setting the header parameter inside the WITH CONNECTION keyword?&lt;/P&gt;&lt;P&gt;From&amp;nbsp;&lt;A href="https://help.qlik.com/en-US/connectors/Subsystems/REST_connector_help/Content/Connectors_REST/Load-REST-data/Load-data.htm#WITH-CONNECTION-keyword" target="_self"&gt;Help&lt;/A&gt;:&lt;/P&gt;&lt;PRE&gt;WITH CONNECTION (
Url "https://localhost:81/northwind2.xml",
QUERY "type" "XML",
QUERY "size" "",
HTTPHEADER "auth_type" "token",
HTTPHEADER "token" "1234123123123",
BODY "Post this");&lt;/PRE&gt;</description>
      <pubDate>Wed, 10 Apr 2019 23:57:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Connectivity-Data-Prep/REST-Connector-header-query-parameter/m-p/1567903#M3817</guid>
      <dc:creator>fosuzuki</dc:creator>
      <dc:date>2019-04-10T23:57:59Z</dc:date>
    </item>
    <item>
      <title>Re: REST Connector header query parameter</title>
      <link>https://community.qlik.com/t5/Connectivity-Data-Prep/REST-Connector-header-query-parameter/m-p/1568666#M3824</link>
      <description>&lt;P&gt;I've tried all of them within the URL connection statement. However, it doesn't work. I managed to fix it by editing the URL with some query parameters inside of it, i.e.&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;https://opendata.cbs.nl/ODataApi/odata/83131NED/TypedDataSet?$filter=Bestedingscategorieen%20eq%20%27T001112%20%20%27&amp;amp;$skip=273&lt;/PRE&gt;&lt;P&gt;As of now I only fetch the category I want.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 12 Apr 2019 09:13:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Connectivity-Data-Prep/REST-Connector-header-query-parameter/m-p/1568666#M3824</guid>
      <dc:creator>klikgevoel</dc:creator>
      <dc:date>2019-04-12T09:13:56Z</dc:date>
    </item>
  </channel>
</rss>

