<?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 Writing back from qlikview to sql in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Writing-back-from-qlikview-to-sql/m-p/1666103#M728066</link>
    <description>&lt;P&gt;HI all,&lt;/P&gt;&lt;P&gt;I have requirement in QlikView&lt;/P&gt;&lt;P&gt;in the access point , there will be&amp;nbsp;3 buttons(yes) button, (NO) button &amp;nbsp;&amp;nbsp;and submit button.&lt;/P&gt;&lt;P&gt;I have created a table in the sql with columns&lt;/P&gt;&lt;P&gt;ID, UserName,Userchoice(this will be yes or No) and updated date .&lt;/P&gt;&lt;P&gt;Now if the user clicks on the Yes&amp;nbsp;button&amp;nbsp; or No button and click on submit button, it needs to get feeded in the database . can anyone please&amp;nbsp;help me as it is very uregent.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV class="mceNonEditable lia-copypaste-placeholder"&gt;&lt;DIV class="mceNonEditable lia-copypaste-placeholder"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;</description>
    <pubDate>Sat, 16 Nov 2024 01:29:55 GMT</pubDate>
    <dc:creator>qlikapple</dc:creator>
    <dc:date>2024-11-16T01:29:55Z</dc:date>
    <item>
      <title>Writing back from qlikview to sql</title>
      <link>https://community.qlik.com/t5/QlikView/Writing-back-from-qlikview-to-sql/m-p/1666103#M728066</link>
      <description>&lt;P&gt;HI all,&lt;/P&gt;&lt;P&gt;I have requirement in QlikView&lt;/P&gt;&lt;P&gt;in the access point , there will be&amp;nbsp;3 buttons(yes) button, (NO) button &amp;nbsp;&amp;nbsp;and submit button.&lt;/P&gt;&lt;P&gt;I have created a table in the sql with columns&lt;/P&gt;&lt;P&gt;ID, UserName,Userchoice(this will be yes or No) and updated date .&lt;/P&gt;&lt;P&gt;Now if the user clicks on the Yes&amp;nbsp;button&amp;nbsp; or No button and click on submit button, it needs to get feeded in the database . can anyone please&amp;nbsp;help me as it is very uregent.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV class="mceNonEditable lia-copypaste-placeholder"&gt;&lt;DIV class="mceNonEditable lia-copypaste-placeholder"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Sat, 16 Nov 2024 01:29:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Writing-back-from-qlikview-to-sql/m-p/1666103#M728066</guid>
      <dc:creator>qlikapple</dc:creator>
      <dc:date>2024-11-16T01:29:55Z</dc:date>
    </item>
    <item>
      <title>Re: Writing back from qlikview to sql</title>
      <link>https://community.qlik.com/t5/QlikView/Writing-back-from-qlikview-to-sql/m-p/1666218#M728067</link>
      <description>&lt;P&gt;Hi!&lt;/P&gt;&lt;P&gt;You can build a macro to create an ODBC/OLEDB connection to the data base and write or update rows. This is not recommended in general but here you have a sample code that I built in QV desktop to test this feature:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;sub test

i_NuevoDepartamento = ActiveDocument.Variables("vNuevoDepartamento").getcontent.string
i_NuevaDescripcion = ActiveDocument.Variables("vNuevoDescDepartamento").getcontent.string

Set objConnection = CreateObject("ADODB.Connection")
Set objRecordset = CreateObject("ADODB.Recordset")

objConnection.Open "DSN=Test_SQLS;"

strSQL_MaxID = "SELECT MAX ([DepartmentID]) as UltimoID FROM [AdventureWorks2017].[HumanResources].[Department]"

objRecordset.CursorLocation = 3
objRecordset.Open strSQL_MaxID, objConnection, 3, 3
objRecordSet.MoveFirst

strSQL_INSERT = "INSERT into [AdventureWorks2017].[HumanResources].[Department] ([Name],[GroupName]) VALUES ("
strSQL_INSERT = strSQL_INSERT &amp;amp; chr(39) &amp;amp; i_NuevoDepartamento &amp;amp; chr(39) &amp;amp; ","
strSQL_INSERT = strSQL_INSERT &amp;amp; chr(39) &amp;amp; i_NuevaDescripcion &amp;amp; chr(39) &amp;amp; ")"

msgbox(strSQL_INSERT)

objConnection.Execute(strSQL_INSERT)

objRecordset.Close
objConnection.Close

end sub&lt;/LI-CODE&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Jaime.&lt;/P&gt;</description>
      <pubDate>Thu, 16 Jan 2020 12:42:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Writing-back-from-qlikview-to-sql/m-p/1666218#M728067</guid>
      <dc:creator>jaibau1993</dc:creator>
      <dc:date>2020-01-16T12:42:11Z</dc:date>
    </item>
    <item>
      <title>Re: Writing back from qlikview to sql</title>
      <link>https://community.qlik.com/t5/QlikView/Writing-back-from-qlikview-to-sql/m-p/1667601#M728068</link>
      <description>&lt;P&gt;can you please share the qvw please&lt;/P&gt;</description>
      <pubDate>Tue, 21 Jan 2020 08:59:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Writing-back-from-qlikview-to-sql/m-p/1667601#M728068</guid>
      <dc:creator>qlikapple</dc:creator>
      <dc:date>2020-01-21T08:59:19Z</dc:date>
    </item>
    <item>
      <title>Re: Writing back from qlikview to sql</title>
      <link>https://community.qlik.com/t5/QlikView/Writing-back-from-qlikview-to-sql/m-p/1675063#M728069</link>
      <description>&lt;P&gt;You do not need the QVW, you simply need to copy/paste the macro code into the Edit Module...&lt;/P&gt;
&lt;P&gt;&lt;A href="https://help.qlik.com/en-US/qlikview/April2019/Subsystems/Client/Content/QV_QlikView/Edit_Module2.htm" target="_blank"&gt;https://help.qlik.com/en-US/qlikview/April2019/Subsystems/Client/Content/QV_QlikView/Edit_Module2.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Please be sure to mark the post as the solution once you can test things, I am guessing the code may need some tweaks to account for your environment info etc...&lt;/P&gt;
&lt;P&gt;Regards,&lt;BR /&gt;Brett&lt;/P&gt;</description>
      <pubDate>Wed, 12 Feb 2020 21:56:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Writing-back-from-qlikview-to-sql/m-p/1675063#M728069</guid>
      <dc:creator>Brett_Bleess</dc:creator>
      <dc:date>2020-02-12T21:56:05Z</dc:date>
    </item>
  </channel>
</rss>

