Python DB API - commit() v. execute("commit transaction")?

Gregory Ewing greg.ewing at canterbury.ac.nz
Fri Jun 2 04:10:51 EDT 2017


Chris Angelico wrote:
> Executing a query gives you some sort of object. That object either
> contains all the results, or has the resource handle (or whatever)
> needed to fetch more from the back end. That basically makes it a
> cursor, so we're not far different after all :)

The point is that my API doesn't make a big deal out of them.
You don't typically think about them, just as you don't usually
think much about the intermediate iterator created when you
do "for x in some_list".

-- 
Greg



More information about the Python-list mailing list