]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
- added very rudimentary yielding iterator behavior to Query. Call
authorMike Bayer <mike_mp@zzzcomputing.com>
Wed, 2 Jan 2008 23:13:02 +0000 (23:13 +0000)
committerMike Bayer <mike_mp@zzzcomputing.com>
Wed, 2 Jan 2008 23:13:02 +0000 (23:13 +0000)
commitebe83b95ad24ae72a151a5f5fdd01a44ceccfef1
treec0e3a9ccc1044ff7abd4516d47d7583f7fb2095e
parente12075efa8b5eb45a918cc150218921d88dc2bec
- added very rudimentary yielding iterator behavior to Query.  Call
query.yield_per(<number of rows>) and evaluate the Query in an
iterative context; every collection of N rows will be packaged up
and yielded.  Use this method with extreme caution since it does
not attempt to reconcile eagerly loaded collections across
result batch boundaries, nor will it behave nicely if the same
instance occurs in more than one batch.  This means that an eagerly
loaded collection will get cleared out if it's referenced in more than
one batch, and in all cases attributes will be overwritten on instances
that occur in more than one batch.
CHANGES
lib/sqlalchemy/orm/query.py
test/orm/query.py