Re: question on UPDATE TABLE
От | Stephan Szabo |
---|---|
Тема | Re: question on UPDATE TABLE |
Дата | |
Msg-id | 20020823124920.H23447-100000@megazone23.bigpanda.com обсуждение исходный текст |
Ответ на | question on UPDATE TABLE (Wei Weng <wweng@kencast.com>) |
Ответы |
Re: question on UPDATE TABLE
|
Список | pgsql-sql |
On 23 Aug 2002, Wei Weng wrote: > I have this query > > UPDATE ONLY ContentSummaries > SET AccessID = '685d96de-1d09-11b2-beec-0001031d54ce' > FROM Categories AS cat, ContentTypes AS ct, ContentSummaries AS cs LEFT > OUTER JOIN Publishers AS pb ON (pb.PublisherID = cs.PublisherID) > WHERE cs.CreationDate IS NOT NULL AND cat.CategoryID = cs.CategoryID AND > ct.ContentTypeID = cs.ContentTypeID AND cat.CategoryID = > '391b11d0-1d09-11b2-a312-0001031d54ce' You do realize you're getting two copies of ContentSummaries in this update and only one is actually being constrained afaics (and it's not the one being updated). Perhaps something like cs.ContentTypeID=ContentSummaries.ContentTypeID or something like that in the where clause?
В списке pgsql-sql по дате отправления: