About Rowstate and AutoIncrement

F

fatboycanteen

When I filled the db data to the dataset

eg. (id_col is autoincrement)
id_col field1
97 100
98 200
99 15
100 72
---

when I add two rows to it (newrow-> table.add)

id_col field1
97 100
98 200
99 15
100 72
101 79 <- new row
102 80 <- new row

then I delete the first row (row.deleted)

id_col field1
97 100 <- marked deleted (rowstate)
98 200
99 15
100 72
101 79
102 80

then I add one row

id_col field1
97 100 <- marked deleted (rowstate)
98 200
99 15
100 72
101 79
102 80
104 77 <- new row

The problem is that the id_col is 104, why not 103

Anyone can solve the problem. Thank You
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,734
Messages
2,569,441
Members
44,832
Latest member
GlennSmall

Latest Threads

Top