I am using Node with node-sqlite3. I cannot seem to delete rows by passing their primary key, but I can delete rows by passing some other column value.
Example
this.db.run("DELETE FROM MyTable WHERE Name = 'Bob'");
No problem. But:
this.db.run("DELETE FROM MyTable WHERE _id = 3);
I have specified _id as my autoincrement / primary key. I can prove this by doing a PRAGMA and showing the debugger's results here, which clearly indicates _id as the pk
PRAGMA call
Debugger
I really don't know what to do as I get no errors from the db.run call
via jozenbasin


No comments:
Post a Comment