The "sqlite3_exec" function has resided in the "legacy.c" file since
shift to version 3. The function is still around in current v3.5 draft
as http://www.sqlite.org/capi350ref.html says.

That function is still kept around for compatibility reasons, as it
was a important function in SQLite v2 days.
On the other side it is quite handy to execute e.g. "create", and
generally for queries that modify the database and don't return data.

Will it stay around for the whole life-span of version 3? Currently, I
prefer to avoid "sqlite3_exec" function, as it's in the "legacy.c"
file and I am unsure about its future.

The official SQLite 3 API documentation says nothing about the legacy
status of the "sqlite3_exec" function:
http://www.sqlite.org/capi3ref.html#sqlite3_exec
... nor any info in the source code, and I haven't found any
information about it beside a short footnote in "The Definitive Guide
to SQLite" book and the "legacy.c" filename in the source code.

My propose, either move function out of legacy file or add some legacy
information text to API documentation (or at least to the source code)
and about its planned life span.




About mutex usage, the following page
http://www.sqlite.org/34to35.html mentions :
"[...] The SQLite source code provides multiple implementations of
these APIs, suitable for varying environments. [...]"
"[...] Embedded applications may wish to provide their own mutex
implementation. [...]"

For Unix, the POSIX Pthreads specification supports mutexes. The four
basic functions are as follows:
* pthread_mutex_init
* pthread_mutex_destory
* ptrhead_mutex_lock
* pthread_mutex_unlock

In Win32 world, the same can be solved by using Win32 Mutex functions
or CRITICAL_SECTIONS (beside others):
* CreateMutex
* ReleaseMutex
* OpenMutex

SQLite 3 already use Win32 Mutex for WinCE (file) locking ("os_win.c"
file). Most of that code could be reused for WinNT Win32 API (with the
help of some macros, because of the "wince" part of the WinAPI
function names).

Will SQLite 3.5 use operating system related mutex API or does it ship
with its own mutex implemented functions (I have seen some related
code, but haven't investigated further)?

-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]
-----------------------------------------------------------------------------

Reply via email to