Marek Kilimajer <mailto:[EMAIL PROTECTED]> on Tuesday, August 26, 2003 3:59 AM said:
> mysql_query() will return true for queries that don't return rows and > were executed without error, so you can use > return mysql_query(); > You should also make a UNIQUE index on email column, then you can > check the number returned by mysql_errno(), one number I don't > remember signals duplicate entry error. OOhhh... You know, I already HAVE done this, and I just came to the realization that if I've already got a constraint on the email column then why the heck am I checking to see if the value is already there? That's just a waste of resources. I should instead just try to perform the INSERT and then if it fails I know I've already got a record. If it doesn't I know everything is cool. Good idea! Chris. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php