Re: Concurrently updating an updatable view - Mailing list pgsql-hackers

From Heikki Linnakangas
Subject Re: Concurrently updating an updatable view
Date
Msg-id 46482B9E.3010805@enterprisedb.com
Whole thread Raw
In response to Re: Concurrently updating an updatable view  (Hiroshi Inoue <inoue@tpf.co.jp>)
Responses Re: Concurrently updating an updatable view  (Richard Huxton <dev@archonet.com>)
List pgsql-hackers
Hiroshi Inoue wrote:
> Heikki Linnakangas wrote:
>> Hiroshi Inoue wrote:
>>> Concurrently updating an updatable view seems to cause
>>> an unexpected result. Is it a known issue?
>> Looks right to me. What did you expect?
> 
> Shouldn't the last response
>   (session-2)
>          UPDATE 1
> 
> be
>   (seesion-2)
>          UPDATE 0
> ?

Ah, I re-read the example and I see what you mean now.

The problem is that the new tuple version is checked only against the 
condition in the update rule, id=OLD.id, but not the condition in the 
original update-claus, dt='a'.

Yeah, that's confusing :(.

--   Heikki Linnakangas  EnterpriseDB   http://www.enterprisedb.com


pgsql-hackers by date:

Previous
From: Hiroshi Inoue
Date:
Subject: Re: Concurrently updating an updatable view
Next
From: Dave Page
Date:
Subject: Re: What is happening on buildfarm member baiji?