Hi,
I cannot get a replace querie to replace data in one table with fields from another. Instead, it appends new rows.
In both tables I made one field a UNIQUE KEY. This field is the common denominator in the two tables. But when I say:
replace tbl1 (fld1, fld2)
select fld1, fld2
from tbl2;
when tbl1.fld3 and tbl2.fld3 are UNIQUE KEYs and they are supposed to be the same in both tables (tbl1 has more entries than tbl2), the querie appends new rows.
What am I doing wrong, that the REPLACE appends instead of updating?
Thank you
I cannot get a replace querie to replace data in one table with fields from another. Instead, it appends new rows.
In both tables I made one field a UNIQUE KEY. This field is the common denominator in the two tables. But when I say:
replace tbl1 (fld1, fld2)
select fld1, fld2
from tbl2;
when tbl1.fld3 and tbl2.fld3 are UNIQUE KEYs and they are supposed to be the same in both tables (tbl1 has more entries than tbl2), the querie appends new rows.
What am I doing wrong, that the REPLACE appends instead of updating?
Thank you