Yes it is possible to create SQLAlchemy models that work on both PostgreSQL and SQLite. I've done it myself. It works ok for simple models and it is relatively easy to mimic Postgres functions as SQLite UDFs.
However it will get harder if you need to use RETURNING queries or other postgres goodies. You may be able to factor out an abstraction but too many of these and you're not really testing your production code any more. So it depends on how what PostgreSQL goodies you feel you need. I would also say that speeding up unit tests is normally possible especially if you lean heavily on native postgres mechanisms for loading fixtures and tearing them down. Stored procedures can be helpful with the teardown or save points. Good luck! Giles Brown -- 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/c146fa73-f68e-42f9-bf75-8d56da819e64o%40googlegroups.com.