Re: about client-side cursors
От | Christophe Pettus |
---|---|
Тема | Re: about client-side cursors |
Дата | |
Msg-id | BAB9FCFC-96F6-48E2-98EA-FF851AA6C884@thebuild.com обсуждение исходный текст |
Ответ на | Re: about client-side cursors (Denis Laxalde <denis.laxalde@dalibo.com>) |
Ответы |
Re: about client-side cursors
|
Список | psycopg |
> On Feb 4, 2021, at 03:16, Denis Laxalde <denis.laxalde@dalibo.com> wrote: > But, unless I missed it, the PEP does not state how to implement query > execution and result fetch operations if the database does not need a > cursor. First, any change like this would have to maintain their current API essentially forever, unless psycopg3 represents a completelyincompatible break with the psycopg2 interface. There is an enormous body of code out there that uses the currentcursor() interface for client-side cursors. Second, it would be very unwise to make guarantees about when these operations interact with the database. I think thatany client application should expect that both cursor.execute() and cursor.fetchone()/.fetchall() are asynchronous operations,and code appropriately. -- -- Christophe Pettus xof@thebuild.com
В списке psycopg по дате отправления: