删除某字段最小的:DELETE FROM OPENING_RECORD WHERE TIME_STAMP = (SELECT MIN(TIME_STAMP) FROM OPENING_RECORD)
查询时排序:database.query(TABLENAME, null, null, null, null, null, "TIME_STAMP DESC");
查询某字段最大值:database.rawQuery("select max(publishTime) from js", null);
某字段条件查询:Cursor cursor = db.query(tableName, null, "name = ?", new String[] { name }, null, null, null);
某字段条件删除:db.delete(tableName, "name = ?", new String[] { name });
某字段条件查询:db.query(tableName, null, "name like ?", new String[] { title }, null, null, null);
Android SQLite 操作
最新推荐文章于 2024-04-10 10:57:16 发布