mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-01-27 23:07:11 +01:00
Added comment
This commit is contained in:
parent
530d726da2
commit
a3e9886142
1 changed files with 2 additions and 0 deletions
|
|
@ -315,6 +315,8 @@ def remove_orphaned_records(self, connection, dbpath):
|
|||
'\n'+tb)
|
||||
|
||||
def get_lastrowid(self, cursor):
|
||||
# SQLite3 + Python has a fun issue on 32-bit systems with integer overflows.
|
||||
# Issue a SQL query instead, getting the value as a string, and then converting to a long python int manually.
|
||||
query = 'SELECT last_insert_rowid()'
|
||||
cursor.execute(query)
|
||||
row = cursor.fetchone()
|
||||
|
|
|
|||
Loading…
Reference in a new issue