Hi
I have to tables and need to merge them.
Tables are with the same structure
table1 - fields a,b,c,d
table2 - fields a,b,c,d
a - is a unique key on which I would like to merge them
I would like to update for instance table2 from table1
if key a exists then table2.b = table2.b+table1.b
if do not exist insert the whole record from table1 to table2
Any idea how to do it ?
Regards
Piotr
I have to tables and need to merge them.
Tables are with the same structure
table1 - fields a,b,c,d
table2 - fields a,b,c,d
a - is a unique key on which I would like to merge them
I would like to update for instance table2 from table1
if key a exists then table2.b = table2.b+table1.b
if do not exist insert the whole record from table1 to table2
Any idea how to do it ?
Regards
Piotr
Last edited: