Thread: Playing with UPDATEs ...

Playing with UPDATEs ...

From
The Hermit Hacker
Date:
Just curious, but shouldn't something like this be possible?  Or is my
syntax just off?

update dict d, dictionary m    set d.word = m.word_val      where d.word = m.word;

I want to go through one table and replace all occurances of every word in
the second table with a numeric value ...

I've tried it as:

update dict, dictionary  set dict.word = dictionary.word_valwhere dict.word = dictionary.word;

and that doesn't work either ...

Marc G. Fournier                   ICQ#7615664               IRC Nick: Scrappy
Systems Administrator @ hub.org 
primary: scrappy@hub.org           secondary: scrappy@{freebsd|postgresql}.org 



Re: [HACKERS] Playing with UPDATEs ...

From
Thomas Lockhart
Date:
update dictset word = m.word_valfrom dictionary mwhere dict.word = m.word;

> I want to go through one table and replace all occurances of every word in
> the second table with a numeric value ...
                 - Thomas

-- 
Thomas Lockhart                lockhart@alumni.caltech.edu
South Pasadena, California