<?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 SQL Insert Data from a variable and from edit script load in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/SQL-Insert-Data-from-a-variable-and-from-edit-script-load/m-p/1665921#M728107</link>
    <description>&lt;P&gt;May seem like a long-ish question.&lt;BR /&gt;I have 1. An input box where users can enter a comma separated list of fruits for example:&lt;BR /&gt;vFruit = apple, orange , mango&lt;/P&gt;&lt;P&gt;2. Clicking on a button creates a reload, which then takes into account how many fruits were entered (here, 3) , then does a sql select from a db and gets me 3 unique IDs, lets say :&lt;BR /&gt;newIDS = &amp;nbsp;123,456,789&lt;/P&gt;&lt;P&gt;What I want:&lt;BR /&gt;The same edit script to do a sql insert:&lt;BR /&gt;sql insert into DB&amp;nbsp;&lt;BR /&gt;values (apple,123),(orange,456),(mango,789) ;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I cant seem to figure out how to create said sql insert statement using the 'newIDS' and looping through all the values in&amp;nbsp;vFruit in the edit script, so that dynamic reload (i have a condition vFlag = 1, so only that portion runs)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you !&lt;/P&gt;</description>
    <pubDate>Sat, 16 Nov 2024 19:17:47 GMT</pubDate>
    <dc:creator>padmanabhv</dc:creator>
    <dc:date>2024-11-16T19:17:47Z</dc:date>
    <item>
      <title>SQL Insert Data from a variable and from edit script load</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-Insert-Data-from-a-variable-and-from-edit-script-load/m-p/1665921#M728107</link>
      <description>&lt;P&gt;May seem like a long-ish question.&lt;BR /&gt;I have 1. An input box where users can enter a comma separated list of fruits for example:&lt;BR /&gt;vFruit = apple, orange , mango&lt;/P&gt;&lt;P&gt;2. Clicking on a button creates a reload, which then takes into account how many fruits were entered (here, 3) , then does a sql select from a db and gets me 3 unique IDs, lets say :&lt;BR /&gt;newIDS = &amp;nbsp;123,456,789&lt;/P&gt;&lt;P&gt;What I want:&lt;BR /&gt;The same edit script to do a sql insert:&lt;BR /&gt;sql insert into DB&amp;nbsp;&lt;BR /&gt;values (apple,123),(orange,456),(mango,789) ;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I cant seem to figure out how to create said sql insert statement using the 'newIDS' and looping through all the values in&amp;nbsp;vFruit in the edit script, so that dynamic reload (i have a condition vFlag = 1, so only that portion runs)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you !&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 19:17:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-Insert-Data-from-a-variable-and-from-edit-script-load/m-p/1665921#M728107</guid>
      <dc:creator>padmanabhv</dc:creator>
      <dc:date>2024-11-16T19:17:47Z</dc:date>
    </item>
    <item>
      <title>Re: SQL Insert Data from a variable and from edit script load</title>
      <link>https://community.qlik.com/t5/QlikView/SQL-Insert-Data-from-a-variable-and-from-edit-script-load/m-p/1675057#M728108</link>
      <description>&lt;P&gt;Firstly, I would caution against performing write-backs to databases using QlikView, this is not really what the product was intended to do and could lead to unintended consequences.&amp;nbsp; That being said, I suspect you have not gotten any responses, as I was a little confused on exactly what you are asking here, it is not clear exactly what piece you need help solving?&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You would need to enable EXECUTE and the Write options in the Desktop Client script editor, not sure whether you have done that or not:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://help.qlik.com/en-US/qlikview/April2019/Subsystems/Client/Content/QV_QlikView/Scripting/ScriptRegularStatements/Execute.htm" target="_blank"&gt;https://help.qlik.com/en-US/qlikview/April2019/Subsystems/Client/Content/QV_QlikView/Scripting/ScriptRegularStatements/Execute.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://help.qlik.com/en-US/qlikview/April2019/Subsystems/Client/Content/QV_QlikView/Edit_Script_dialog_box.htm" target="_blank"&gt;https://help.qlik.com/en-US/qlikview/April2019/Subsystems/Client/Content/QV_QlikView/Edit_Script_dialog_box.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;See Settings option on the second link to allow the Read/Write.&lt;/P&gt;
&lt;P&gt;Best I can offer with what you provided.&lt;/P&gt;
&lt;P&gt;Regards,&lt;BR /&gt;Brett&lt;/P&gt;</description>
      <pubDate>Wed, 12 Feb 2020 21:36:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/SQL-Insert-Data-from-a-variable-and-from-edit-script-load/m-p/1675057#M728108</guid>
      <dc:creator>Brett_Bleess</dc:creator>
      <dc:date>2020-02-12T21:36:20Z</dc:date>
    </item>
  </channel>
</rss>

