Hi, David... ApiLogicServer <https://github.com/valhuber/ApiLogicServer#readme> bundles a version of sqlacodegen, and creates the models.py file (along with a running project). Don't know if this fits your needs, hope it helps.
On Sunday, July 3, 2022 at 6:15:03 AM UTC-7 david...@gmail.com wrote: > I want to be able to auto generate sqlalchemy model from a schema. > So I have the schema in yaml format. > From that file, I load it and get the columns and its data type and also > the schema name into a dict. And I want to use that dictionary to create > the sqlalchemy model not just a normal python class > > I have done some research and I see you can use sqlachemy's automap > feature to do what I want but that is when you supply a DB connection uri. > Likewise sqlacodegen > -- SQLAlchemy - The Python SQL Toolkit and Object Relational Mapper http://www.sqlalchemy.org/ To post example code, please provide an MCVE: Minimal, Complete, and Verifiable Example. See http://stackoverflow.com/help/mcve for a full description. --- You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To unsubscribe from this group and stop receiving emails from it, send an email to sqlalchemy+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/sqlalchemy/4cec0f13-2157-4263-ac1e-d298e53a2e8fn%40googlegroups.com.