[Freeswitch-users] Lua and database access to core_db

Jon Bruel jbr at consiglia.dk
Tue Dec 8 03:46:26 PST 2009


I got the combination Lua with direct access to the core Sqlite database to work. Hurray, maybe I'm not as stupid as A.M II hints...
The problem was that Lua did not "like":

    require "luasql.sqlite"
    env = luasql.sqlite()
    con = assert(env:connect("/usr/local/freeswitch/db/core.db"))

After changing it to

    require "luasql.sqlite3"
    env = luasql.sqlite3()
    con = assert(env:connect("/usr/local/freeswitch/db/core.db"))

And seeing that there was a symlink in one of the right directories called with the name: sqlite3.so, it worked.

Changing the core db into a MySQL via ODBC caused some problems even after it seemed to work. For instance, console help caused an error with an error description indicating that a SQL SELECT query including the reserved word key has been fired.

It this problem likely to be solved if I used another version of the MySQL?

Jon Brüel
Consiglia Telecommunications
DK-2960 Rungsted Kyst
Tel: +45 45 16 1000
Mob: +45 26 15 30 60
CVR: 27047882


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20091208/4764dc8a/attachment-0002.html 


More information about the FreeSWITCH-users mailing list