- changed milestone to 0.8.xx
Confusing wording on yield_per
Issue #2616
resolved
The docs seem to say that psycopg2 doesn't stream results with yield_per, isn't that the opposite?
Comments (5)
-
repo owner -
Account Deleted Ah, now I understand.
Also note that while yield_per() will set the stream_results execution option to True, currently this is only understood by psycopg2, which will stream results using server side cursors. Other DBAPIs (XX any exceptions to mention here?) do not “stream” results at all, pre-buffering all rows before making them available. (or: No DBAPI is known to stream results by default, instead pre-buffering etc).
-
Made a pull request: https://github.com/zzzeek/sqlalchemy/pull/17
-
repo owner - changed status to resolved
this is in master/0.8/0.7: 0d4b769d6aed2979 7da90f41b269f7b4 bb290b46a65d51f thanks !
-
repo owner - removed milestone
Removing milestone: 0.8.xx (automated comment)
- Log in to comment
the situation is: mysqldb and psycopg2 do not stream results by default - they buffer them. psycopg2 offers an option called "server side cursors", which when used, causes psycopg2 to not buffer results. the "stream_results" execution option is a SQLAlchemy option which establishes this status on the psycopg2 cursor, and is implicit when yield_per() is used.
OK with those facts, let me know that you understand them, then please suggest a wording that you feel is more clear. thanks !