[sqlalchemy] Setting up eager loading after query runs

2008-07-12 Thread Kyle Schaffrick
I can't figure out any good way to phrase my question without some pipe-laying, so here I go... I have a pattern of doing some various query activities in my app that ultimately result in retrieving a single instance of one of my mapped classes from the ORM. So naturally I stuck that pattern in

[sqlalchemy] Setting up eager loading after query runs

2008-07-12 Thread Kyle Schaffrick
On Sat, 12 Jul 2008 16:02:15 -0400 Rick Morrison [EMAIL PROTECTED] wrote: Suppose you have a list result of a simple query: vector = S.query(MappedObj).filter(foo).all() and assume MappedObj has a simple relation children, each of those in turn having a simple relation

[sqlalchemy] Setting up eager loading after query runs

2008-07-12 Thread Kyle Schaffrick
On Sat, 12 Jul 2008 22:01:50 +0300 [EMAIL PROTECTED] wrote: after the Query is long gone? if it is really gone/done, who should eager-load? I assume that it would be possible to do it after the Query is gone, at least in theory, since lazy-loaded attributes are able to trigger eager-loads