gda_connection_error: Missing or wrong arguments for table '_collations'
While trying the Python examples I found that meta_store.py
could be made to work with libgda 5.2.9 but not 6.0.0, this snippet:
import gi
gi.require_version("Gda", "6.0")
from gi.repository import GLib
from gi.repository import Gda
GLib.unlink("meta_store.db")
c = Gda.Connection.open_from_string("SQLite", "DB_DIR=.;DB_NAME=meta_store", None, Gda.ConnectionOptions.NONE)
c.execute_non_select_command("CREATE TABLE user (name string PRIMARY KEY, functions string, security_number integer)")
c.execute_non_select_command("INSERT INTO user (name, functions, security_number) VALUES ('Martin Stewart', 'Programmer, QA', 2334556)")
cx = Gda.MetaContext()
print("Updating Meta Store for table 'customers' columns...")
cx.set_table("_columns")
c.update_meta_store(cx)
results in:
Updating Meta Store for table 'customers' columns...
Traceback (most recent call last):
File "/var/tmp/connection_error.py", line 17, in <module>
c.update_meta_store(cx)
gi.repository.GLib.Error: gda_connection_error: Missing or wrong arguments for table '_collations': {_collations}=>{{no constraints in context}} (11)
SQLite 3.34.0