Is there a straightforward way to query an SQLiteDatabase with selection args that are not String types?
Particularly: if the arg is a
also you may try
Cursor cs = db.rawQueryWithFactory(new CursorFactory() {
@SuppressLint("NewApi")
@SuppressWarnings("deprecation")
@Override
public Cursor newCursor(SQLiteDatabase db, SQLiteCursorDriver masterQuery,
String editTable, SQLiteQuery query) {
// bind it here!...
query.bindBlob(1, mac);
if (Build.VERSION.SDK_INT < 11) {
return new SQLiteCursor(db, masterQuery, editTable, query);
} else {
return new SQLiteCursor(masterQuery, editTable, query);
}
}
}, query, null, DB_TABLE);