That's what I originally did but it can create loads of problems if you remove entries from the database or something similar.
Is it SQL you're using? If so then i BELIEVE that there is a way of defining a field to do this automatically, instead of calling a field 'int' or whatever, I remember there being a 'counter' attribute or something similar. Can't remember it offhand just now. Does anyone else here know what it's called? Ross James Mansfield wrote: > > OK...newbie question it must be: > I want to add an entry into a db tb (using php obviously) and when its added > into the db its gets a sequencially numberred id....now can I retrieve this > id numbe rin the same php coded page as what I create the entry with? If not > what is the best way around it? Create a unique number for the entry before > adding it into db?? > > -- > PHP Windows Mailing List (http://www.php.net/) > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]