Skip to content

Commit

Permalink
Document sqlite3.Cursor.close()
Browse files Browse the repository at this point in the history
The behaviour of the close method is tested by ClosedCurTests
in Lib/sqlite3/test/dbapi.py.

This is basically a backport of ghaering/pysqlite#73.
  • Loading branch information
berkerpeksag committed Mar 27, 2016
1 parent 557a063 commit f70fe6f
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions Doc/library/sqlite3.rst
Original file line number Diff line number Diff line change
Expand Up @@ -593,6 +593,12 @@ Cursor Objects
the cursor's arraysize attribute can affect the performance of this operation.
An empty list is returned when no rows are available.

.. method:: close()

Close the cursor now (rather than whenever ``__del__`` is called).

The cursor will be unusable from this point forward; a ``ProgrammingError``
exception will be raised if any operation is attempted with the cursor.

.. attribute:: rowcount

Expand Down

0 comments on commit f70fe6f

Please sign in to comment.