如何使这条线工作?
return ourDatabase.rawQuery("SELECT * FROM GL_" + tablename + " WHERE " + KEY_GROUP_T + " = " + grp + " ORDER BY " + KEY_NAME_T + " COLLATE NOCASE", null);
04-23 17:58:26.701:E/AndroidRuntime(9212):原因:android.database.sqlite.SQLiteException:没有这样的列:Baked_Goods:,编译时:SELECT * FROM GL_table4 WHERE grlist_group = Baked_Goods ORDER BY grlist_name COLLATE NOCASE
这条线正在工作,但我想用 rawQuery 来做:
return ourDatabase.query("GL_" + tablename, columns, KEY_GROUP_T + "= ?" , new String[]{grp}, null, null, null);