New submission from Matthew Woodcraft <matt...@woodcraft.me.uk>:

The documentation for the sqlite3 module contains the following statement, 
under 'Cursor.rowcount':

  For DELETE statements, SQLite reports rowcount as 0 if you make a DELETE FROM 
table without any condition.

This doesn't happen for me (with sqlite 3.7.9): rowcount returns the correct 
value in this case.

According to http://www.sqlite.org/lang_delete.html#truncateopt , this was a 
bug that was fixed in SQLite 3.6.5 (in 2008).

So I think the Python documentation should either omit this paragraph, or else 
explain that it only applies to older versions of SQLite.


Also, the first example under 'Using shortcut methods' has code to work around 
this bug, which should perhaps be removed.

----------
assignee: docs@python
components: Documentation
messages: 153136
nosy: docs@python, mattheww
priority: normal
severity: normal
status: open
title: sqlite3 Cursor.rowcount documentation for old sqlite bug

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue13995>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to