Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Write-back Capability in Qlikview

Hello All,

Wethere its possible to write back capability to an teradata database table in qlikview 9 ? If it's possible can you please let me know the procedure to do it?

For Example :

If user select some rules (Business rules) in qlikview .That rules will directly add in terdata database table not only add need update and delete the existing rule in the database table.

Thanks in advance!

By

Shiva B

4 Replies
Anonymous
Not applicable
Author

Yes, but it might be a bit tricky. You could do a macro that connects to the DB and writes updates based on values in your .qvw file if you want it to happen on the fly.

Not applicable
Author

Thanks

Not applicable
Author

Hi Shiva_QV,

I had a simlair issue recently where I needed to write back to a SQL server.  Here is the macro that I used, word of warning if you intend people to use this over the webserver you are going into a very tricky area as Johannes mentioned:

sub Connection

     set conn=CreateObject("ADODB.Connection")
     conn.Open "Provider='sqloledb';Data Source='<YOUR SERVER HERE>';Initial Catalog='<YOUR DATABASE HERE>>';Integrated   Security='SSPI';"
     set rs=CreateObject("ADODB.recordset")

' Database Update

     sql="update [CompletionFlag] set [DashboardUpdated]= 1 where id = (select max(id) from completionflag) and dateadd(d, 0, datediff(d, 0,[Datestamp])) = dateadd(d, 0, datediff(d, 0, isnull(getdate(),'1900-01-01')))"

     on error resume next
     conn.Execute sql
     if err <> 0 then
          msgbox("No update permissions! " & err )
     end if

     conn.close
end sub

agomes1971
Specialist II
Specialist II

Hi,

the most elegant solution:

SQL Writeback from QlikView extension object.

Hope it helps

André Gomes