I need to reset the row number count to 1. How can I do that?
An example for an update query in my code:
public boolean update (long rowId, String title, String body, String reminderDateTime, String loca, String type, String settime, String lat, String llong) {
ContentValues args = new ContentValues();
args.put(KEY_TITLE, title);
args.put(KEY_BODY, body);
args.put(KEY_DATE_TIME, reminderDateTime);
args.put(KEY_LOCATION, loca);
args.put(KEY_TYPE, type);
args.put(KEY_SETTIME, settime);
args.put(KEY_LAT, lat);
args.put(KEY_LONG, llong);
return mDb.update(DATABASE_TABLE, args, KEY_ROWID + "=" + rowId, null) > 0;
I tried to do that but the eclipse showing me an error:"sqlite_sequence cannot be resolved to a variable"
public void resetAutoNumbering ()
{
mDb.update(sqlite_sequence, args, KEY_ROWID + "=" + rowId, null);
}
What can I do and how?