SQLAlchemy
SQLAlchemy looks like a very interesting ORM for Python developers.
According to their website
SQLAlchemy is:- a library that provides enterprise-level persistence patterns: eager loading of multiple types of objects using outer joins, Data Mapper, Unit of Work, all-or-nothing commits, bind parameters used for all literal values, batched updates and deletes.
The project is very young, but from what I can see all the pieces are already there and working. I wish I had more time to get involved, because this looks like it has a chance to become one of the best ORM’s out there.
And it’s about time Python got and ORM that could knock hibernate down off of it’s pedestal. I only say this because it ought to be so much easierto do this kind of thing really well in a dynamic language, so it’s a bit embarrassing that the Java has a better ORM than the Python. The hibernate team even had to do some bytecode hacking (though they are doing it in a nice way!) to make what they do possible, but all that reflection and dynamism is just there to be used in Python with no extra hacks required.
Another interesting tidbit from the SQLAlchemy web site:
SQLAlchemy’s Philosophy:
SQL databases behave less and less like object collections the more size and performance start to matter; object collections behave less and less like tables and rows the more abstraction starts to matter. SQLAlchemy aims to accommodate both of these principles.
This seems to me to be a very good philosophy, but as always it’s the implementation details that make the philosophy work out in practice.
0 Responses to “SQLAlchemy”