At 21:27 -0500 5/23/02, Andrew Lietzow wrote:
>Dear MySQL wizards,
>
>I have two tables, call them A and B.   The database structure is identical. 
>I want the records in B to overwrite the records in (REPLACE INTO) A. 
>
>This is the statement that does NOT work.
>
>REPLACE INTO a SELECT b.* FROM b WHERE a.field1 = b.field1
>
>I also tried this with the last the conditional statement reversed.  MySQL
>doesn't like my syntax.   The field names in A are identical to B. 
>
>TIA for any help.  
>
>--
>Andrew Lietzow
>The ACL Group, Inc.

The SELECT part has to be a legal SELECT statement, which yours
isn't.  (The WHERE part names two tables, but the FROM part names
only one.)

---------------------------------------------------------------------
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

Reply via email to