AlgebraicJulia / AlgebraicRelations.jl

Relational Algebra, now with more algebra!
https://www.algebraicjulia.org
MIT License
48 stars 3 forks source link

Ingesting a SQL Schema to create an Algebraic Theory #11

Open jpfairbanks opened 3 years ago

jpfairbanks commented 3 years ago

We can represent relational database schemas as free categories with catlab, but we should support the automatic creation of the indexing category from a SQL schema. I think there are commands you can issue to a PGSQL server which will return a table containing all the information about the tables and indexes. We could compute the indexing category of a C-Set from that information and automatically populate a PGSQL database into a C-Set. Similar functionality exists in SQLite databases.