> At 7:43 AM -0400 10/5/07, Dan Shirah wrote: > >Ah, what a lovely case of the Friday morning brain farts! > > > >I have a query that selects some data from a table based on the current ID > >selected. > > > >If the query does not return any results, I want it to continue to another > >query that will insert a record into the table. if you don't actually need to know inside of PHP whether or not it exists, you can skip the PHP work and have mysql do it for you: http://dev.mysql.com/doc/refman/5.0/en/insert-on-duplicate.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php