I\'d like to filter a SimpleCursorAdapter-driven ListView with an EditText box right above it. I have the following code, but when I type in the box, nothing happens; the fu
Try this way:
} else {
String value = "%"+constraint.toString()+"%";
return mDB.query(directoryPeople.PEOPLE_TABLE, asColumnsToReturn, "LAST_NAME like ? ", new String[]{value}, null, null, null);
}
I skipped the last argument because I don't know what it really should do:
"CASE WHEN LAST_NAME like '" + constraint.toString() + "%' THEN 0 ELSE 1 END, LAST_NAME"
Have you tried this query in shell in emulator?