AndrewMozley
Programmer
I have Table1 which has two fields, cRef_t1 and nValue_t1. cRef_t1 is populated, and there is also Table2 which has the values I want. Each record in Table2 which has a particular reference, cRef_t2, has a corresponding value nValue_t2.
I know that I can put the values into Table1 with code something like:
SELECT Table1
SCAN
SELECT Table2
SEEK Table1.cRef_t1
SELECT Table1
REPLACE nValue_t1 WITH Table2.nValue_t2
ENDSCAN
However this can perhaps be done (updating all the records in Table1) with something like this :
SELECT nValue FROM Table2 a, Table2 b WHERE a.cRef_t1 = b.cRef_t2
. . .
But I have run out of steam there! Is there an SQL statement which can update a table with values from another table?
Thanks. Andrew M.