Issue Details (XML | Word | Printable)

Key: PYFB-64
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Pavel Cisar
Reporter: Jan Michalski
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Firebird driver for Python

cursor.description throws ReferenceError after executemany INSERT

Created: 10/Mar/16 07:09 PM   Updated: 15/Feb/17 12:02 PM
Component/s: None
Affects Version/s: 1.5.1
Fix Version/s: 1.6

Environment: Archlinux 4.4.1-2 x86_64; Python 2.7


 Description  « Hide
ReferenceError is thrown when accessing cursor description after calling executemany with an INSERT.

======== Example code below: =========
import fdb
 
connection = fdb.create_database("CREATE DATABASE '/tmp/test.db' user 'SYSDBA' password 'masterkey'")
 
cursor = connection.cursor()
 
cursor.execute("CREATE TABLE TEST (ID INTEGER PRIMARY KEY)")
connection.commit()
cursor.executemany("INSERT INTO TEST VALUES(?)", [(1,), (2,)])
 
print cursor.description

======================
Traceback (most recent call last):
  File "test.py", line 11, in <module>
    print cursor.description
  File "/home/hator/PythonEnvs/konkret-raporty/lib/python2.7/site-packages/fdb/fbcore.py", line 3296, in __get_description
    return self._ps.description
ReferenceError: weakly-referenced object no longer exists




 All   Comments   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
There are no comments yet on this issue.