[odb-users] SQLite3 Version (and Native View Question)
Boris Kolpackov
boris at codesynthesis.com
Wed Jan 25 07:07:11 EST 2023
Brian E. Coggins <becoggins at hotmail.com> writes:
> 1. Can we expect a newer version of sqlite3 to be incorporated into
> ODB’s distribution soon? (Or I am dumb and missing an already-existing
> update, perhaps by using bpkg incorrectly?)
SQLite is not really a part of the ODB distribution but rather a
package that libodb-sqlite depends on. We've published 3.39.4 that
includes the functionality you are looking for:
https://cppget.org/libsqlite3
> 2. I thought about switching to the system's libsqlite3, except that
> seems to be a mess. [...]
Yeah, I am not sure what's going on there. I would suggest that you
try to upgrade to 3.39.4 from the above package and see if that fixes
things.
> 3. Absent a sqlite3 upgrade, I thought I’d try to workaround the
> lack of outer join support by using a complex query of the
> structure WITH (xxx UNION yyy) SELECT zzz as part of my ODB
> native view. The query works in the sqlite3 CLI, but the ODB
> compiler complains “view XXX has an incomplete query template
> and no associated objects.” Is the ODB compiler trying to parse
> the query and getting hung up on this syntax? Any advice?
Yes, it tries to guess whether it's a complete query or the WHERE
clause by checking if the query starts with one of the known keywords
(like SELECT). I have a TODO item to recognize some additional database-
specific keywords (like WITH).
More information about the odb-users
mailing list