Closed tabinfl closed 2 years ago
I think this is the only sane way - there is code that does something similar in the ETS core. It would be possible to parse the schema to see how the table was created, but that is probably too brittle.
I think @bradh is referring to https://github.com/opengeospatial/ets-gpkg12/blob/master/src/main/java/org/opengis/cite/gpkg12/CommonFixture.java#L243.
moved to :point_up:
The PRAGMA query return data allows checking everything but the UNIQUE constraint on the mapping_table_name field.
could add
to check for unique = 1 and then
to verify that it's on the correct (mapping_table_name) column.
There may be an easier way, I keep running into sqlite's limited SQL.