Re: [sqlalchemy] Documentation for joined table inheritance - Engineer.id renders as people.id

2012-06-17 Thread Michael Bayer
it was referring to a generic query against Engineer, that is Session.query(Engineer). Though it likely puts both columns in the query these days.The phrase has been removed and a note about the change from 0.6 to 0.7 has been added there as well (see http://www.sqlalchemy.org/trac/wiki/07

[sqlalchemy] Documentation for joined table inheritance - Engineer.id renders as people.id

2012-06-17 Thread Yap Sok Ann
In the documentation for joined table inheritance [1], it mentions that: > Note that above, the Engineer.id attribute, since it shares the same attribute name as the Person.id attribute, will in fact represent the people.id and engineers.id columns together, and will render inside a query as "p

Re: [sqlalchemy] Connection events don't work on connection objects?

2012-06-17 Thread Michael Bayer
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 There's a patch attached to http://www.sqlalchemy.org/trac/attachment/ticket/2511/ that does most of it now, in case you want to play with it. Still some glitches need to be ironed out, though. On Jun 17, 2012, at 9:31 AM, Michael Bayer wrote: >

Re: [sqlalchemy] Connection events don't work on connection objects?

2012-06-17 Thread Michael Bayer
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 unfortunately that is the case for now. the event system doesn't actually have the capability for one class of events to be associated with more than one type of parent class. it will be a non-trivial task to get both Engine and Connection to ac

[sqlalchemy] Connection events don't work on connection objects?

2012-06-17 Thread Fayaz Yusuf Khan
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 This code fails:- from sqlalchemy import event, create_engine def before_execute(conn, clauseelement, multiparams, params): log.info("Received statement: %s" % clauseelement) engine = create_engine('mysql://root@localhost') connection = engine.c