Search Results

Search found 3 results on 1 pages for 'luasql'.

Page 1/1 | 1 

  • Luasql and SQLite?

    - by OverTheRainbow
    Hello I just got started looking at Lua as an easy way to access the SQLite DLL, but I ran into an error while trying to use the DB-agnostic LuaSQL module: require "luasql.sqlite" module "luasql.sqlite" print("Content-type: Text/html\n") print("Hello!") Note that I'm trying to start from the most basic setup, so only have the following files in the work directory, and sqlite.dll is actually the renamed sqlite3.dll from the LuaForge site: Directory of C:\Temp <DIR> luasql lua5.1.exe lua5.1.dll hello.lua Directory of C:\Temp\luasql sqlite.dll Am I missing some binaries that would explain the error? Thank you. Edit: I renamed the DLL to its original sqlite3.dll and updated the source to reflect this (originally renamed it because that's how it was called in a sample I found). At this point, here's what the code looks like... require "luasql.sqlite3" -- attempt to call field 'sqlite' (a nil value) env = luasql.sqlite() env:close() ... and the error message I'm getting: C:\>lua5.1.exe hello.lua lua5.1.exe: hello.lua:4: attempt to call field 'sqlite' (a nil value)

    Read the article

  • Lua SQL: peeking at cursors

    - by NP
    I am using LuaSQL, and query for a result set using con:execute(sql_stmt), which returns a cursor. How do I see if there is at least one row in that resultset, without doing a cursor:fetch to pop that first row?

    Read the article

1