mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-01-30 07:45:08 +01:00
Query for FavouritesIndex only for KTouch and database versions that support it
This commit is contained in:
parent
cdd6637598
commit
a8a2db1313
1 changed files with 5 additions and 1 deletions
|
|
@ -203,8 +203,12 @@ def update_booklist(prefix, path, title, authors, mime, date, ContentType, Image
|
|||
result = cursor.fetchone()
|
||||
self.dbversion = result[0]
|
||||
|
||||
query= 'select Title, Attribution, DateCreated, ContentID, MimeType, ContentType, ' \
|
||||
if self.dbversion >= 14:
|
||||
query= 'select Title, Attribution, DateCreated, ContentID, MimeType, ContentType, ' \
|
||||
'ImageID, ReadStatus, ___ExpirationStatus, FavouritesIndex from content where BookID is Null'
|
||||
else:
|
||||
query= 'select Title, Attribution, DateCreated, ContentID, MimeType, ContentType, ' \
|
||||
'ImageID, ReadStatus, ___ExpirationStatus, "-1" as FavouritesIndex from content where BookID is Null'
|
||||
|
||||
cursor.execute (query)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue