View Single Post
  #8  
Old 06-12-2003, 03:13 PM
Lurker_005
Demi-God
 
Join Date: Jan 2002
Location: Tourist town USA
Posts: 1,671
Default

Quote:
Originally Posted by Muuss
select max(id) from doors;

will give you only one row with the biggest value of the id field

select count(id) from doors;

will give you the number of records
First by default you don't want any door ID's above 9999 unless you modified the doors.h file and recompiled

If those two do not give you similar numbers (within say 1000 of each other) then you have lots of unused ID's This happens when the table data is deleted, the next insert will use the next highest ID from what was there (unless the ID is specified)

You can drop the table, then recreate it then reload the doors and things should be better. I imagine there is a command that compacts the table and can get the ID's sequential, but I can't think of it right now. Anyone?
__________________
Please read the forum rules and look at reacent messages before posting.
Reply With Quote