On Friday 16 March 2007 18:23, Jerry Hill wrote:
> On 3/16/07, jim-on-linux <[EMAIL PROTECTED]> 
wrote:
> > Below, the first select produces results but,
> > after closing then re-opening the database
> > the select produces an empty list.  Anyone
> > know the reason ??
>
> When you first open a connection, you
> implicitly begin a transaction. You need to
> call con.commit() before you close the
> connection, or your transaction will be rolled
> back when you close() it.  If don't want to
> bother with transaction handling, you can turn
> it off when you open the connection, like this:
> con = sqlite3.connect('myData',
> isolation_level=None)
>
> See the Python Database API 2.0 PEP for more
> details about the behavior required of DB-API
> 2.0 compliant interfaces:
> http://www.python.org/dev/peps/pep-0249/
>
> --
> Jerry

Thanks, this saves a lot of con.commit action.
And the website is valuable.

jim-on-linux 
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to