Uploaded 'sqlite.lsp' bindings for the SQLite database. Works on Friday's upload of newLISP version 7.4.7, which can import libraries compiled for 'cdecl' calling conventions. Also tested on LINUX and FreeBSD. With this file and the new 'cdecl' parameter in newLISP 'import' you don't need a separate wrapper DLL on Win32.
This library import is also a good demo what to do with things like 'char *** pazValue' or 'char **pzErrmsg'. Nested multiple pointers can all be handled with the right mixture of 'get-integer' and 'get-string'.
SQLite fits very good to newLISP, because it is small and 'in process' so it doesn't need a separate database server running. The generated databases are binary compatible on all platforms. Seems to be the ideal database if MySQL still seems to be too much for the task.
By the way I have monitored the SQLite mailing list some time, and I think a lot of people use it on a lot of platforms for heavy database jobs with a lot more record than 20000. It is not a full-fledge oracle, but for SQL92 it is very fast and small.
With sqlite 3.03 beta sqlite goes into the next major version.
The next 3.0 release will probably be called a final or stable release.
Since the API changed slightly (sqlite_compile is now sqlite3_prepare etc.) we need a new sqlite3.lsp.
I have tried with simple replacing, but had no success so far. (Crashing)
Features:
A more compact format for database files.
Manifest typing and BLOB support.
Support for both UTF-8 and UTF-16 text.
User-defined text collating sequences.
64-bit ROWIDs.
Improved Concurrency.
I looked into this some time ago and it is definetely more than a name change. The old interface already had to deal with 'C' pointers to pointers and data structures. A slight change in this means to look into it again more carefully. It all can be done, but one has to read the docs for the 'C' interface again. If you want to go at it, I suggest you first study the old docs and 'C' interface to understand the pointer stuff how its done in newLISP and then approach the new stuff.
There are two modes to interact with SQLite one with call back, the other one without, using sqlite_compile(), sqlite_step() and sqlite_finalize(). Of course we want the method without callbacks.