UPDATE

P

Piotr

I have following problem and I cant find any solution by myself:

I have two tables, table 1 and table 2, they consist records with two
fields in table 1 field A and B and in table 2 fields C and D:

UPDATE field B by field D if field A=C

I need this for data transformation purpose, please tell me if u know
the solution.

regards
Peter
 
R

RoyVidar

It happens that Piotr formulated :
I have following problem and I cant find any solution by myself:

I have two tables, table 1 and table 2, they consist records with two
fields in table 1 field A and B and in table 2 fields C and D:

UPDATE field B by field D if field A=C

I need this for data transformation purpose, please tell me if u know
the solution.

regards
Peter

Hi!

The tables can be joined on table1.a and table2.c?

If so, try (on a copy first, perhaps?)

update table1 inner join table2 on table1.a = table2.c
set table1.b = table2.d
 
P

Piotr

RoyVidar said:
It happens that Piotr formulated :

Hi!

The tables can be joined on table1.a and table2.c?

If so, try (on a copy first, perhaps?)

update table1 inner join table2 on table1.a = table2.c
set table1.b = table2.d

Hi, it works great !
thank you
 
Top