C
ChaosKCW
Hi
I am trying to use pymssql, and have an issue where by the execute
(not the fetch) is appearing to load all records into memory.
if I execute
con = pymssql.connect(...)
cur = con.cursor()
cur.execute(sql)
rec = cur.fetchone()
if I put in a query which returns a lot of records into "sql" then the
execute never returns, pythons memory usage slowly ballons till the
machine cant give anymore. If I put a sql query returning only few
rows, then it works fine.
So I am not sure why an execute would feel the need to load all rows,
but its seriously crippling. Does anyone know if this is a bug or
something I can "turn off"
thanks,
I am trying to use pymssql, and have an issue where by the execute
(not the fetch) is appearing to load all records into memory.
if I execute
con = pymssql.connect(...)
cur = con.cursor()
cur.execute(sql)
rec = cur.fetchone()
if I put in a query which returns a lot of records into "sql" then the
execute never returns, pythons memory usage slowly ballons till the
machine cant give anymore. If I put a sql query returning only few
rows, then it works fine.
So I am not sure why an execute would feel the need to load all rows,
but its seriously crippling. Does anyone know if this is a bug or
something I can "turn off"
thanks,