Re: BUG #3764: Update count returns zero for a view with 'on update' rules when criteria contains updatable field

From: "Eugene Hutorny" <eugene(at)ksf(dot)kiev(dot)ua>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "Peter Eisentraut" <peter_e(at)gmx(dot)net>
Cc: <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: BUG #3764: Update count returns zero for a view with 'on update' rules when criteria contains updatable field
Date: 2007-11-21 10:00:45
Message-ID: 007601c82c25$659b0750$82a8a8c0@ksf
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

This 'feature' makes such a view unusable in the clients (MS Access or any
other ADO based) that *do verify* update count and report an error if it is
not of expected value.
Is there a workaround for this?

Peter, you mentioned it is documented, may you please point me to the
document you meant?

----- Original Message -----
From: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Eugene M. Hutorny" <eugene(at)ksf(dot)kiev(dot)ua>
Cc: <pgsql-bugs(at)postgresql(dot)org>
Sent: Tuesday, November 20, 2007 8:28 PM
Subject: Re: [BUGS] BUG #3764: Update count returns zero for a view with 'on
update' rules when criteria contains updatable field

"Eugene M. Hutorny" <eugene(at)ksf(dot)kiev(dot)ua> writes:
> I noticed strange behaviour of update statements issued to a view with an
> 'on update' rule when the where criterion contains the field being
updated.

This isn't a bug --- once the first update is performed, the visible
view contents change and so the second update finds no matching row.

regards, tom lane

----- Original Message -----
From: "Peter Eisentraut" <peter_e(at)gmx(dot)net>
To: <pgsql-bugs(at)postgresql(dot)org>
Cc: "Eugene M. Hutorny" <eugene(at)ksf(dot)kiev(dot)ua>
Sent: Tuesday, November 20, 2007 7:58 PM
Subject: Re: [BUGS] BUG #3764: Update count returns zero for a view with 'on
update' rules when criteria contains updatable field

Am Dienstag, 20. November 2007 schrieb Eugene M. Hutorny:
> Description: Update count returns zero for a view with 'on update'
> rules when criteria contains updatable field

This is known and documented.

--
Peter Eisentraut
http://developer.postgresql.org/~petere/

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Zdenek Kotala 2007-11-21 10:10:07 Re: BUG #3763: crash after create table with primary keydefined
Previous Message Tom Lane 2007-11-21 05:11:39 Re: BUG #3767: tsearch2 index creation fatal crash