Ask Your Question

LibreofficeBase: how to execute SQL from BASIC script [closed]

asked 2013-08-07 17:45:46 +0200

Python gravatar image

I have an application where I need to execute a SQL command from BASIC script. I found how to do it not long ago, but now I cannot find it.

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by Alex Kemp
close date 2015-11-07 23:33:53.696427

1 Answer

Sort by » oldest newest most voted

answered 2013-08-07 17:49:43 +0200

Python gravatar image

updated 2013-08-07 17:50:33 +0200

From googles cached page of

REM make sure your connected to the database
if IsNull(ThisComponent.CurrentController.ActiveConnection) then

REM execute!
Dim oStatement As Object
oStatement = ThisComponent.CurrentController.ActiveConnection.createStatement()
oStatement.execute("SOME SQL COMMAND")
edit flag offensive delete link more

Question Tools

1 follower


Asked: 2013-08-07 17:45:46 +0200

Seen: 2,706 times

Last updated: Sep 06 '13