RE: [PHP] Pragmatically changing a "Record Number"
| From: | Bastien Koert | Date: | Wed, 29 Aug 2007 20:53:30 +0000 |
| Subject: | RE: [PHP] Pragmatically changing a "Record Number" | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-261512@lists.php.net to get a copy of this message | ||
Please don't do that...autonumber should not be relied for anything other than a unique row
identifier. It should NOT matter to the application what that value is as long as it unique. If you
need a count of the number of records, do a query (select count(*) from table...)
bastien> To: php-general@lists.php.net> From: japruim@raoset.com> Date: Wed, 29 Aug 2007
bastien> 13:49:02 -0400> Subject: [PHP] Pragmatically changing a "Record Number"> > Hi
bastien> Everyone,> > I think after I get this question answered, I can stop asking for > awhile
bastien> since my project will be done, at least until the users say > "What happened to
bastien> XYZ????" then I'll ask again :)> > I asked on a MySQL list about "Resetting a
bastien> auto increment filed" so > that there arn't any gaps in the record number.> > So
bastien> to say it another way, I have a table that has 900 records in it, > I've added 3 records,
bastien> but then deleted 2 of those which puts the > actual record count at 901 but my auto increment
bastien> field starts at 904 > on the next insert.> > Is there away with PHP that I can
bastien> pragmatically change that value to > the total records in the database more so then a
bastien> representation of > the actual record number?> > > --> > Jason Pruim> Raoset
bastien> Inc.> Technology Manager> MQC Specialist> 3251 132nd ave> Holland, MI, 49424>
bastien> www.raoset.com> japruim@raoset.com> >
_________________________________________________________________
Explore the seven wonders of the world
http://search.msn.com/results.aspx?q=7+wonders+world&mkt=en-US&form=QBRE