Re: Pragmatically changing a "Record Number"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On Aug 29, 2007, at 1:58 PM, Jay Blanchard wrote:

[snip]
Is there away with PHP that I can pragmatically change that value to
the total records in the database more so then a representation of
the actual record number?
[/snip]	

1. Changing the values in an auto-increment column is just Bad[tm],
especially if you are using it as a unique index.

It's not yet, and I don't plan to have it be part of a unique index, unless I absolutely need to onceI look into being able to search...

2. You can get a row count using mysql_num_rows()

3. Ask yourself, "Is it important to keep the auto-increment field
contiguous?"

The main reason for changing it is I do currently have an option to sort by record number, although, if I add a Record number in php, but still have it sort based off of the record number stored in the database, it would still sort right, but also look right...


4. You can always display a row number with PHP that is contiguous, but
not representative of the actual column.



I think you may have made me go a different way in my thinking. Thank you :)


--

Jason Pruim
Raoset Inc.
Technology Manager
MQC Specialist
3251 132nd ave
Holland, MI, 49424
www.raoset.com
japruim@xxxxxxxxxx

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux