[sqlalchemy] Re: Problem with mapper relationship when lazy=False

2006-10-23 Thread Steve Zatz

 youre really looking to have an association object pattern here.
I thought you might recommend that.  My problem last time I tried an
association object was that in the following situation:

item table
keyword table
itemkeyword table (and association object)

I couldn't get the keywords to eager load when I retrieve items, which
is the reason I am trying to kluge this together without an association
object.  I'll go back and see if I can retrieve items and then do

keywords = [ik.keyword for ik in item.itemkeywords]

without SQLAlchemy querying the database each time separately from the
query that brings back the items.


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
sqlalchemy group.
To post to this group, send email to sqlalchemy@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/sqlalchemy
-~--~~~~--~~--~--~---



[sqlalchemy] Re: Problem with mapper relationship when lazy=False

2006-10-23 Thread Steve Zatz

 the eager load should be able to go through the association object
 down to the endpoint Keyword objects
Thanks -- that does work.


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
sqlalchemy group.
To post to this group, send email to sqlalchemy@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/sqlalchemy
-~--~~~~--~~--~--~---