plugin:struct:dbinternals
This is an old revision of the document!
Database Internals
The struct plugin maps the a relatively dynamic schema mechanism on a much more rigid relational database system. It also needs to take care that schemas evolve over time, but data in the past has to be preserved and the appropriate schema at that time need to be used.
To do this, schemas in struct do not map directly to tables in the database.
SELECT S.ts, S.tbl, T.label, SC.colref, T.ismulti FROM schemas S, schema_cols SC, types T WHERE SC.sid = S.id AND SC.tid = T.id AND SC.enabled = 1 GROUP BY S.tbl, T.label HAVING MAX(S.ts) ORDER BY S.tbl, SC.sort ;
work in progress…
plugin/struct/dbinternals.1651750632.txt.gz · Last modified: 2022-05-05 13:37 by andi