SQl function in android
- by rui.pereira
Cursor cursor = db.rawQuery("SELECT COUNT(rat)
FROM "+ TABLE_NAME_EXTRA +" apkid=\""+apkid, null);
cursor.moveToFirst();
int somatotal = cursor.getInt(0);
I'm trying to do a SQL function like count and sum, but this code returns a exception saying "emptyvalues".
anyone know why?