RE: [PHP-DB] auto increment
| From: | José Moreira | Date: | Fri, 14 Jun 2002 08:52:36 +0000 |
| Subject: | RE: [PHP-DB] auto increment | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-19802@lists.php.net to get a copy of this message | ||
hello, i think u have to create the series yourself ... before u insert
every record, first calculate the next value :
"SELECT MAX(ID) AS NEXT FROM TABLE"
then u insert ...
hope it helps ...
-----Mensagem original-----
De: Daniele Baroncelli [mailto:daniele@baroncelli.com]
Enviada: sexta-feira, 14 de Junho de 2002 2:27
Para: php-db@lists.php.net
Assunto: [PHP-DB] auto increment
Hi guys,
The auto_increment field of my MySQL table gives me "258", although the
higher value at the moment is "241".
I deleted the latest records, thinking that also the auto_increment would
decrease, but this is not.
I would like to know if there is a way to bring the auto_increment back to
the higher value + 1.
Cheers
Daniele
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php