Question: Correcting MySQL's ID colomn when removing an entry
| From: | Parham Doustdar | Date: | Sun, 20 Sep 2009 07:37:39 +0000 |
| Subject: | Question: Correcting MySQL's ID colomn when removing an entry | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-298189@lists.php.net to get a copy of this message | ||
Hello there,
I'm guessing that when a row in a MySQL table is removed, the ID colomns of the rows which come
after that row are not changed. For example:
1
2
3
4
Now, if I want to remove the third rows, the ID colomn would be something like:
1
2
4
I was wondering if there was a way to fix it through a query, so I wouldn't have to use a for
statement in PHP to fix it?
Thanks!
--
---
Contact info:
Skype: parham-d
MSN: fire_lizard16 at hotmail dot com
GoogleTalk: parham90@gmail.com
Twitter: PD90
email: parham90 at GMail dot com