<?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: User Input Variable direct to WHERE statement in SQL load query in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/User-Input-Variable-direct-to-WHERE-statement-in-SQL-load-query/m-p/1982586#M1221077</link>
    <description>&lt;P&gt;I think I got it solved.&lt;/P&gt;
&lt;P&gt;1 : Create two variables (vMaterial_ID , vLocation_ID) in sheet&lt;/P&gt;
&lt;P&gt;2 : In sheet use extension 'Variable input', make two seperate inputs and assign one to each variable.&lt;/P&gt;
&lt;P&gt;3: In Data Load Editor in each SQL query have 'WHERE material_ID in ($(vMaterial_ID)) AND location_Id in&amp;nbsp;($(vPlant_ID))&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It worked and only retrieved rows where search matched what I put in variable.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;*A caveat more towards the SQL query is they have to be prepared 'like','this',with','commas' and apostophes. So it will be one huge string in the input variable box on the sheet.&lt;/P&gt;</description>
    <pubDate>Mon, 19 Sep 2022 13:22:40 GMT</pubDate>
    <dc:creator>Cassidyd90</dc:creator>
    <dc:date>2022-09-19T13:22:40Z</dc:date>
    <item>
      <title>User Input Variable direct to WHERE statement in SQL load query</title>
      <link>https://community.qlik.com/t5/QlikView/User-Input-Variable-direct-to-WHERE-statement-in-SQL-load-query/m-p/1982448#M1221068</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;I have SQL load scripts with 2 fields in the WHERE part. Is there a way to get user input (multiple strings) into the script, then reload app?&lt;/P&gt;
&lt;P&gt;I guess it would be by using variables like&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;WHERE material_id IN (&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;inputVar1&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;)&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;AND Location_ID IN (&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;inputVar2&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;)&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 19 Sep 2022 10:07:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/User-Input-Variable-direct-to-WHERE-statement-in-SQL-load-query/m-p/1982448#M1221068</guid>
      <dc:creator>Cassidyd90</dc:creator>
      <dc:date>2022-09-19T10:07:44Z</dc:date>
    </item>
    <item>
      <title>Re: User Input Variable direct to WHERE statement in SQL load query</title>
      <link>https://community.qlik.com/t5/QlikView/User-Input-Variable-direct-to-WHERE-statement-in-SQL-load-query/m-p/1982478#M1221070</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/198642"&gt;@Cassidyd90&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;you can enter the value of&amp;nbsp;&lt;STRONG&gt;inputVar1/2&amp;nbsp;&amp;nbsp;&lt;/STRONG&gt;into Excel files and load the excel to model before the SQL load,&lt;BR /&gt;if that option&amp;nbsp;possible for you I can expand on that if necessary&lt;/P&gt;</description>
      <pubDate>Mon, 19 Sep 2022 10:36:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/User-Input-Variable-direct-to-WHERE-statement-in-SQL-load-query/m-p/1982478#M1221070</guid>
      <dc:creator>MendyS</dc:creator>
      <dc:date>2022-09-19T10:36:41Z</dc:date>
    </item>
    <item>
      <title>Re: User Input Variable direct to WHERE statement in SQL load query</title>
      <link>https://community.qlik.com/t5/QlikView/User-Input-Variable-direct-to-WHERE-statement-in-SQL-load-query/m-p/1982495#M1221072</link>
      <description>&lt;P&gt;Hi MendyS,&lt;/P&gt;
&lt;P&gt;I see what you mean and yes that may be a solution.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The complication is that I have multiple SQL queries to draw info from cloud database.&lt;/P&gt;
&lt;P&gt;Each query will have the var1/2 input (material_id + location_id) but I would prefer not to join the tables in Data Model because they are for very different reasons/checks and will return an enormous amount of extra rows.&lt;/P&gt;
&lt;P&gt;It would be 6 SQL queries = 6 tables (unlinked) with 6 sheets representing findings.&lt;/P&gt;
&lt;P&gt;Any idea how to go about that?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;*Important that I only load tables with data that matches input or else will have millions of rows in each table.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks for you help.&lt;/P&gt;</description>
      <pubDate>Mon, 19 Sep 2022 11:06:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/User-Input-Variable-direct-to-WHERE-statement-in-SQL-load-query/m-p/1982495#M1221072</guid>
      <dc:creator>Cassidyd90</dc:creator>
      <dc:date>2022-09-19T11:06:42Z</dc:date>
    </item>
    <item>
      <title>Re: User Input Variable direct to WHERE statement in SQL load query</title>
      <link>https://community.qlik.com/t5/QlikView/User-Input-Variable-direct-to-WHERE-statement-in-SQL-load-query/m-p/1982586#M1221077</link>
      <description>&lt;P&gt;I think I got it solved.&lt;/P&gt;
&lt;P&gt;1 : Create two variables (vMaterial_ID , vLocation_ID) in sheet&lt;/P&gt;
&lt;P&gt;2 : In sheet use extension 'Variable input', make two seperate inputs and assign one to each variable.&lt;/P&gt;
&lt;P&gt;3: In Data Load Editor in each SQL query have 'WHERE material_ID in ($(vMaterial_ID)) AND location_Id in&amp;nbsp;($(vPlant_ID))&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It worked and only retrieved rows where search matched what I put in variable.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;*A caveat more towards the SQL query is they have to be prepared 'like','this',with','commas' and apostophes. So it will be one huge string in the input variable box on the sheet.&lt;/P&gt;</description>
      <pubDate>Mon, 19 Sep 2022 13:22:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/User-Input-Variable-direct-to-WHERE-statement-in-SQL-load-query/m-p/1982586#M1221077</guid>
      <dc:creator>Cassidyd90</dc:creator>
      <dc:date>2022-09-19T13:22:40Z</dc:date>
    </item>
  </channel>
</rss>

