Re: [Sqlalchemy-tickets] [sqlalchemy] #2928: yield_per working with oursql but not with mysqldb
Brought to you by:
zzzeek
|
From: sqlalchemy <mi...@zz...> - 2014-01-30 13:37:56
|
#2928: yield_per working with oursql but not with mysqldb
-----------------------------------+------------------------------------
Reporter: postpawl | Owner:
Type: defect | Status: closed
Priority: medium | Milestone:
Component: mysql | Severity: no triage selected yet
Resolution: invalid | Keywords:
Progress State: completed/closed |
-----------------------------------+------------------------------------
Changes (by zzzeek):
* status: new => closed
* resolution: => invalid
* status_field: awaiting triage => completed/closed
Comment:
this is MySQLdb's behavior, not SQLAlchemy's. The docs are pretty clear
http://docs.sqlalchemy.org/en/rel_0_9/orm/query.html?highlight=yield_per#sqlalchemy.orm.query.Query.yield_per:
Also note that while yield_per() will set the stream_results execution
option to True, currently this is only understood by psycopg2 dialect
which will stream results using server side cursors instead of pre-buffer
all rows for this query. Other DBAPIs pre-buffer all rows before making
them available.
OurSQL is another DBAPI that has the advantage of being able to stream
rows.
--
Ticket URL: <http://www.sqlalchemy.org/trac/ticket/2928#comment:1>
sqlalchemy <http://www.sqlalchemy.org/>
The Database Toolkit for Python
|