| From: | <operationsengineer1(at)yahoo(dot)com> | 
|---|---|
| To: | "pgsql-novice(at)postgresql(dot)org" <pgsql-novice(at)postgresql(dot)org> | 
| Subject: | Problem UPDATE Statement | 
| Date: | 2006-01-04 22:29:18 | 
| Message-ID: | 20060104222918.29693.qmail@web33307.mail.mud.yahoo.com | 
| Views: | Whole Thread | Raw Message | Download mbox | Resend email | 
| Thread: | |
| Lists: | pgsql-novice | 
i'm trying to apply the following UPDATE statement:
UPDATE t_sn
SET t_sn.sn_completed = false
WHERE sn = 1
AND t_sn.link_id = t_link.link_id
AND t_link.job_id = t_job.job_id
AND t_job.product_id = t_product.product_id
AND t_product.product_id = 118
i get the following error:
ERROR: missing FROM-clause entry for table "t_link"
i'm assigning the two values that i know (sn (serial
number) and product_id) and then i'm trying to connect
via my foreign/primary key definitions.  i have the
"logic" to this point.  i ahve some books, but they
tend to have simple examples - nothing like doing an
update and traversing across 4 tables to get the data
required (in my case - t_sn, t_link, t_job,
t_product).
i'm a little frustrated b/c my paradigm is obviously
wrong, but it isn't obvious to me what i'm doing
wrong.  it doesn't help that is a different error each
time, either.
as always, any help/guidance is greatly appreciated.
		
__________________________________________ 
Yahoo! DSL  Something to write home about. 
Just $16.99/mo. or less. 
dsl.yahoo.com 
| From | Date | Subject | |
|---|---|---|---|
| Next Message | operationsengineer1 | 2006-01-04 22:32:43 | Re: Best way to manage users | 
| Previous Message | Sean Davis | 2006-01-04 22:26:56 | Re: Best way to manage users |