1 Jul 2009 03:32
Re: Python sqlite binding: commit inside select loop
I did some checking on the pysqlite mailing list. Apparently the change to reset all cursors before commit is recent, and the reason is that pysqlite or sqlite itself would return bogus rows. There is an example here: http://article.gmane.org/gmane.comp.python.db.pysqlite.user/2217 Returning old or new data would be one thing, but in this example, totally wrong data is returned. There's no explanation of why it was happening. On 6/30/09, Jim Wilcoxson <prirun@...> wrote: > Thanks for the comments and explanations everyone - much appreciated. > It seems there are a few alternatives I can check out. > > Jim > > On 6/30/09, Roger Binns <rogerb@...> wrote: >> -----BEGIN PGP SIGNED MESSAGE----- >> Hash: SHA1 >> >> Jim Wilcoxson wrote: >>> I guess I am a bit confused. Igor says it's not possible, but Roger >>> says my example works. >> >> For the exact code you were running the error message came from pysqlite >> and not from SQLite. Other posters are not aware of the underlying >> implementation details in pysqlite and it doing all sorts of transaction >> related stuff behind the scenes, and so were telling you about SQLite >> behaviour in general. In summary the behaviour you see from pysqlite(Continue reading)
RSS Feed