On Monday 03 September 2007, Steve Finkelstein wrote:
How're you folks dealing with records that are auto incremented in MySQL
after a delete is made? I've noticed the only way to get a sequential order
back is to truncate the table completely.
Do you use logic in your code to find a missing
Steve Finkelstein wrote:
Do you use logic in your code to find a missing ID and insert new
records based on that? Or do you just ignore it, let mysql handle the
numbering and go on with your lives?
The latter.
/Per Jessen, Zürich
--
PHP General Mailing List (http://www.php.net/)
To
[snip]
Do you use logic in your code to find a missing ID and insert new
records
based on that? Or do you just ignore it, let mysql handle the numbering
and
go on with your lives?
[/snip]
The answer is B. There is a long standing discussion on this right now.
--
PHP General Mailing List
-general
php-general@lists.php.net
Sent: Tuesday, September 04, 2007 12:53 PM
Subject: RE: [PHP] Dealing with auto-increment in MySQL
[snip]
Do you use logic in your code to find a missing ID and insert new
records
based on that? Or do you just ignore it, let mysql handle the numbering
and
go
[snip]
I was wondering if people is asking this in the belief that the
autoincrement field is the record position in the database table and
that by
not reusing those positions, the space of the deleted records is
wasted.
Perhaps when they say renumbering what they are meaning is compacting
the
At 1:15 PM +0200 9/4/07, Satyam wrote:
I was wondering if people is asking this in the belief that the
autoincrement field is the record position in the database table and
that by not reusing those positions, the space of the deleted
records is wasted. Perhaps when they say renumbering what
I just let it go...there is no need to manage that process or you'll just screw
up the mysql...
it shouldn't be relied on for anything other that uniqueness any way
bastien
Date: Mon, 3 Sep 2007 23:53:22 -0400 From: [EMAIL PROTECTED] To:
php-general@lists.php.net Subject: [PHP]
On Sep 4, 2007, at 7:15 AM, Satyam wrote:
I was wondering if people is asking this in the belief that the
autoincrement field is the record position in the database table
and that by not reusing those positions, the space of the deleted
records is wasted. Perhaps when they say
Jason Pruim wrote:
As the person who started the other thread about this ...
As one of the people responsible for dragging that thread out ...
But after discussing it, I see where my thinking was wrong in how I
wanted to achieve it, and also my misunderstanding of the way databases
On Sep 4, 2007, at 12:20 PM, brian wrote:
Jason Pruim wrote:
As the person who started the other thread about this ...
As one of the people responsible for dragging that thread out ...
But after discussing it, I see where my thinking was wrong in how
I wanted to achieve it, and also my
Jason Pruim wrote:
On Sep 4, 2007, at 12:20 PM, brian wrote:
Jason Pruim wrote:
so to put my 2¢ in on this, I would say to leave alone the auto
increment field especially if it's included in an index. If you
need a record number, either store it in the database in a separate
field
At 12:08 PM -0400 9/4/07, Jason Pruim wrote:
On Sep 4, 2007, at 7:15 AM, Satyam wrote:
I was wondering if people is asking this in the
belief that the autoincrement field is the
record position in the database table and that
by not reusing those positions, the space of
the deleted records
tedd wrote:
Jason:
Well, at least you read and comprehended what was said -- that's better
than some.
Cheers,
tedd
--
---
http://sperling.com http://ancientstones.com http://earthstones.com
Nice. Good luck with your database endeavours!
brian
--
PHP General Mailing List
At 8:12 PM -0400 9/4/07, brian wrote:
tedd wrote:
Jason:
Well, at least you read and comprehended what was said -- that's
better than some.
Cheers,
tedd
--
---
http://sperling.com http://ancientstones.com http://earthstones.com
Nice. Good luck with your database endeavours!
brian
Steve Finkelstein wrote:
How're you folks dealing with records that are auto incremented in MySQL
after a delete is made? I've noticed the only way to get a sequential order
back is to truncate the table completely.
Do you use logic in your code to find a missing ID and insert new records
based
On Mon, Sep 03, 2007 at 11:53:22PM -0400, Steve Finkelstein wrote:
How're you folks dealing with records that are auto incremented in MySQL
after a delete is made? I've noticed the only way to get a sequential order
back is to truncate the table completely.
Re-numbering is a bad idea for
16 matches
Mail list logo