Emiliano Heyns
unread,Feb 12, 2026, 11:47:18 AM (6 days ago) Feb 12Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to zotero-dev
I am executing this
await Zotero.DB.executeTransaction(async () => {
await Zotero.DB.queryAsync('ATTACH DATABASE ? AS betterbibtex', [ db ])
const rows = await Zotero.DB.queryAsync(`
SELECT bbt.itemID, bbt.itemKey, bbt.libraryID, bbt.citationKey, bbt.pinned
FROM betterbibtex.citationkey bbt
JOIN items item ON item.itemID = bbt.itemID
WHERE item.itemID NOT IN (SELECT itemID FROM deletedItems)
AND item.itemID NOT IN (SELECT itemID FROM feedItems)
AND item.itemTypeID NOT IN (
SELECT itemTypeID
FROM itemTypes
WHERE typeName IN ('attachment', 'note', 'annotation')
)
`.replace(/\n/g, ' '))
but rows is `undefined`. Under what conditions can this plausibly happen? I can run this query in the sqlite cli without issue.