On 3/28/2014 7:56 AM, Kleiner Werner wrote:
Does this mean, if there are 10 rows with id 1 -10 and I delete row with id 5, 
then the next insert will be ID = 5?
Or is next ID = 11?

Here's a more interesting example: you have ten rows with ids 1-10. You delete the row with id of 10 (the last row). You then insert a new row.

Without AUTOINCREMENT, the new row will be given an id of 10 in the current SQLite implementation (it chooses current largest ID + 1). With AUTOINCREMENT, it will be given an id of 11 (SQLite chooses all time high watermark + 1).
--
Igor Tandetnik

_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to