Check the mySQL REPLACE syntax... that's what you need. -----Message d'origine----- De : Corey Wallis [mailto:[EMAIL PROTECTED]] Envoyé : vendredi 26 juillet 2002 11:17 À : [EMAIL PROTECTED] Objet : Fw: Complex SQL assistance
Peoples, I'm currently trying to work out if this is possible by SQL. I have the need to use SQL and only SQL to achieve the following. If a record exists and meets a certain criteria (i.e. field X = '1234') then update the record. If the record doesn't exist then insert it. For reasons too complex to go into at this stage using anything except SQL is not possible. Any and all suggestions welcome. -Corey --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php