If this behavior is a bug , I can build out a testcase.   FWIW , I think 
it's a bug.

    class Foo :
          id = int primary key
          bar = relationship(bar)
          baz = relationship(baz)


    # hits the db
    a = session.query( Foo ).get(1) 

    # doesn't hit the db
    b = session.query( Foo ).get(1) 
    c = session.query( Foo ).options( joinedload('bar'), 
subqueryload('baz')).get(1) 

    # hits the db
    print c.bar
    print c.baz

shouldn't `c` hit the database , in order to pull the explicitly requested 
eager loaded options ?

if not, is there a way to trigger this ?   I need to load all the 
"eagerloaded" attributes before we push data into the templates.  i could 
do this manually on each .get(), but that would be way uglier than anything 
official.



-- 
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sqlalchemy+unsubscr...@googlegroups.com.
To post to this group, send email to sqlalchemy@googlegroups.com.
Visit this group at http://groups.google.com/group/sqlalchemy.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to