What is the syntax for "not equal" in SQLite?
Solution 1:
From the official documentation:
The non-equals operator can be either
!=
or<>
So your code becomes:
Cursor findNormalItems = db.query("items", columns, "type != ?",
new String[] { "onSale" });
Solution 2:
You should use in the comparator the non-equal operator:
"type!=?"
or "type<>?"
.