wxSQLite3 |
| Categories: database | Status: STABLE | ![]() |
| Author: Ulrich Telle | wxWidgets supported ports: wxMSW, wxGTK, wxMac | |
| Current maintainer: Ulrich Telle | wxWidgets supported versions: 2.8, 2.9, 3.0 | |
| Latest version: 3.2.1 | Build system: Bakefile-based | |
| Programming language: C++ | Samples provided: 2 | |
| External dependencies: SQLite database | Documentation: doxygen | |
| Description: wxSQLite3 is a C++ wrapper around the public domain SQLite 3.x database and is specifically designed for use in programs based on the wxWidgets library. wxSQLite3 does not try to hide the underlying database, in contrary almost all special features of the current SQLite3 version 3.8.8.3 are supported, like for example the creation of user defined scalar or aggregate functions. Since SQLite stores strings in UTF-8 encoding, the wxSQLite3 methods provide automatic conversion between wxStrings and UTF-8 strings. The methods ToUTF8 and FromUTF8 of the wxString class (available since wxWidgets 2.8.4) are used for the conversion. Special care has to be taken if external administration tools are used to modify the database contents, since not all of these tools operate in Unicode or UTF-8 mode. wxSQLite3 includes an optional extension for SQLite supporting key based database file encryption using 128 bit AES encryption. Starting with version 1.9.6 of wxSQLite3 the encryption extension is compatible with the SQLite amalgamation source. Experimental support for 256 bit AES encryption has been added in version 1.9.8. !!! IMPORTANT NOTICE !!! Starting with version 3.3.0 (December 2015) further development of this component moved to GitHub (https://github.com/utelle/wxsqlite3). | ||
| Links for wxSQLite3: › Website | › Screenshots | › Documentation | › Browse Subversion | › Download | | ||
Important notice | ^ TOP |
Starting with version 3.3.0 (December 2015) further development of this component moved to GitHub.
Documentation | ^ TOP |
The doxygen-generated documentation for this component is available online here. Please let me know if you think something is missing.
Known bugs | ^ TOP |
Symptom: Endless recursion in method wxSQLite3StringCollection::operator= on assignment.
Affected version(s): 2.0.0 2.1.3
Solution:
Fixed in wxCode SVNSymptom: Method wxSQLite3Table::GetDouble fails to convert strings to double values in non-US locales.
Affected version(s): all up to 1.9.2
Solution:
Upgrade to version 1.9.3.
Fixed in version 1.9.3Symptom: Method TableExists sometimes fails to find a table due to case sensitive search.
Affected version(s): 1.4.1 1.8.3
Solution:
Upgrade to version 1.8.4.
Fixed in version 1.8.4Symptom: Included Windows SQLite DLLs and SQLite shell crash on initialization due to build error in FTS3 extension.
Affected version(s): 1.8.2
Solution:
Please download the fixed SQLite DLLs from CVS or build the SQLite DLL yourself.
Fixed in version 1.8.3Symptom: Wrong type of transaction is issued in method wxSQLite3Database::Begin when requesting an exclusive transaction.
Affected version(s): 1.4.1 1.8.1
Solution:
Change the following 2 lines in method wxSQLite3Database::Begin in wxsqlite3.cpp:
case WXSQLITE_TRANSACTION_EXCLUSIVE:
sql << _T("begin immediate transaction");
to
case WXSQLITE_TRANSACTION_EXCLUSIVE:
sql << _T("begin exclusive transaction");
Fixed in version 1.8.2Symptom: Compile time error in method wxSQLite3Database::GetBlob when using gcc compiler.
Affected version(s): 1.8.0
Solution:
Make the following change in wxsqlite3.cpp:
Add explicit type cast in line 2018: const char* localDbName = (!dbName.IsEmpty()) ? (const char*) strDbName : (const char*) NULL;
Fixed in version 1.8.1Symptom: Reusing a wxSQLite3Database instance of an encrypted database for a unencrypted database causes problems, since the instance is still flagged as encrypted.
Affected version(s): 1.7.x 1.8.0
Solution:
Make the following change in wxsqlite3.cpp:
Add the following statement after line 1773: m_isEncrypted = false;
Fixed in version 1.8.1Symptom: On big endian platforms the SQLite encryption extension included in wxSQLite3 unfortunately creates non-portable database files since the used MD5 algorithm does not take endianess into account as it should.
Affected version(s): 1.7.x
Solution:
Upgrade to version 1.7.3.
Fixed in version 1.7.3Symptom: In the minimal sample application meta data and encryption support is always enabled.
Affected version(s): 1.7.1
Solution:
Make the following changes in minimal.cpp:
Line 236: Change #ifdef WXSQLITE3_HAVE_METADATA to #if WXSQLITE3_HAVE_METADATA.
Line 159 and 403: Change #ifdef WXSQLITE3_HAVE_CODEC to #if WXSQLITE3_HAVE_CODEC.
Fixed in version 1.7.2Symptom: The call to sqlite3_rekey in wxSQLite3Database::ReKey could cause a program crash, when used to encrypt a previously unencrypted database due to a NULL pointer exception.
Affected version(s): 1.7.0
Solution:
Upgrade to version 1.7.1.
Fixed in version 1.7.1Symptom: In method wxSQLite3Database::TableExists mingw reports a warning, program crashes when calling the method.
Affected version(s): 1.0 1.4.0
Solution:
In call to sprintf replace localTableName by (const char*) localTableName, that is, add an explicit cast of (const char*) for the sprintf argument localTableName.
Fixed in version 1.4.1
To submit a bug report please look at wxCode support page.
Future enhancements | ^ TOP |
To submit a feature request please look at wxSQLite3 issues page.
Links | ^ TOP |
Thanks to Hakki Dogusan dynamic loading of the SQLite library was introduced in version 1.4 of wxSQLite3. Additionally Hakki Dogusan has created a Lua binding for wxSQLite3.
Supporting further development | ^ TOP |
If you find wxSQLite3 useful and would like to support the further development of this wxWidgets component, you may make a donation by clicking on the button on the left. |


