Update to SQLite 3.13 or Newer and Improve how Xojo uses it

feedback://showreport?report_id=43956 Update to SQLite 3.12.2 or Newer

Please update to SQLite 3.12.2 or newer. Visit http://sqlite.org/changes.html for all the improvements and bug fixes since versions 3.9.2 and 3.8.8 (used on iOS).

Hopefully SQLite Encryption Extension (SEE) supports SQLite 3.12.2 or newer.

Ir use Christian’s replacement plugin which is far superior anyway.

http://www.monkeybreadsoftware.de/xojo/plugin-sql.shtml

I updated to 3.13.0 yesterday.
Uploading new plugins now.

Christian’s MBS SQL Plugin is an excellent alternative but Xojo should continue to advance the version of SQLite and improve how it is used.

Regarding SQLite and improving how Xojo uses it, here are some Feedback cases that have yet to be Fixed or Closed.

feedback://showreport?report_id=42544 The entire app hangs during the SQLITE timeout
feedback://showreport?report_id=38161 enable useful sqlite options that are normally off
feedback://showreport?report_id=37698 IOS application quits on the device and not on simulator when trying to use text coming from a SQLite query
feedback://showreport?report_id=37170 Allow more attached databases to be use in SQLite
feedback://showreport?report_id=31055 AES-256 Encryption for SQLite
feedback://showreport?report_id=26859 compile sqlite with icu support for better international support
feedback://showreport?report_id=25257 Add Database.OpenTransaction method

[quote=267614:@Frederick Roller]Regarding SQLite and improving how Xojo uses it, here are some Feedback cases that have yet to be Fixed or Closed.

feedback://showreport?report_id=25257 Add Database.OpenTransaction method[/quote]

Why would one not just do:

dbh.SQLExecute ("begin transaction") dbh.SQLExecute ("commit")

Works well for me.

shouldn’t that be

dbh.SQLExecute ("begin transaction")
dbh.SQLExecute ("end transaction")

[quote=267692:@Tim Streater]Why would one not just do:

dbh.SQLExecute ("begin transaction") dbh.SQLExecute ("commit")

Works well for me.[/quote]
It’s about consistency and completeness. If there are Commit and Rollback methods, there should be a Begin method. Otherwise, drop the Commit and Rollback methods. For consistency in our code, we use SQLExecute with Begin, Commit and Rollback.

[quote=267694:@Dave S]shouldn’t that be

dbh.SQLExecute ("begin transaction") dbh.SQLExecute ("end transaction") [/quote]
Depends on the database. SQLite accepts the commands with or without Transaction following Begin, Commit and Rollback.

https://www.sqlite.org/lang_transaction.html

You can say “end” or commit", they are equivalent. And “transaction” is optional. See:

http://www.sqlite.org/lang_transaction.html

I don’t see the point of the Commit and Rollback methods, myself.

Much more important would be to fix the timeout issue listed in case 42544.

The point would be consistency across disparate database engines. Xojo should hide the details so the developer doesn’t have to remember if it’s “end transaction” or “commit” for any give db. Your code should be able to switch backends without a lot of recoding.

Please consider SQLite 3.13 as the minimum version. It has been available for about two months with no patches, which I interpret as meaning it is a solid release. Hopefully that is the case and it, or a later version, is included in the next release of Xojo.

How Xojo updates SQLite:

2013r1: 23060 Database: SQLiteDatabase/REALSQLDatabase: updated to SQLite 3.7.14.1. 2013r41: 25806 Database: Updated SQLiteDatabase to use SQLite 3.7.17. 2014r2: 29171 SQLiteDatabase: Updated to SQLite version 3.8.5. 2015r1: 36218 SQLiteDatabase: Updated to SQLite 3.8.8. 2015r4: 40510 Framework » All SQLiteDatabase updated to SQLite version 3.9.2.

This means that they carefully choose the SQLite version to include in Xojo.

Of course I do not have a single information on when Xojo will update its SQLite version: a new version of SQLite will be integrated in Xojo when it will be integrated (as usual).

MBS uses the latest one.

Yes, I can just rebuild with a new build.

3.14.0 will be there in a few days and of course instantly be available in MBS SQL Plugin :slight_smile: