[sqlalchemy] How do I get an object from a relationship by object's PK?

2012-08-21 Thread Sergey V.
Hi all, I've asked this question on stackoverflow: http://stackoverflow.com/questions/12031861/sqlalchemy-how-do-i-get-an-object-from-a-relationship-by-objects-pk/12032405 Basically, I'm looking for a dict-like access to a relationship to be able to quickly retrieve items by some key (item's

Re: [sqlalchemy] How do I get an object from a relationship by object's PK?

2012-08-21 Thread Michael Bayer
On Aug 21, 2012, at 5:47 PM, Sergey V. wrote: Hi all, I've asked this question on stackoverflow: http://stackoverflow.com/questions/12031861/sqlalchemy-how-do-i-get-an-object-from-a-relationship-by-objects-pk/12032405 Basically, I'm looking for a dict-like access to a relationship to be