Re: PostgreSQL BugTool Submission

From: Stephan Szabo <sszabo(at)megazone23(dot)bigpanda(dot)com>
To: pgsql-bugs(at)postgresql(dot)org
Subject: Re: PostgreSQL BugTool Submission
Date: 2000-08-22 21:14:16
Message-ID: Pine.BSF.4.10.10008221409590.22911-100000@megazone23.bigpanda.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs


On Tue, 22 Aug 2000 pgsql-bugs(at)postgresql(dot)org wrote:

> James Aspnes (aspnes(at)cs(dot)yale(dot)edu) reports a bug with a severity of 2
> The lower the number the more severe it is.
>
> Short Description
> checking foreign keys requires write access
>
> Long Description
> In version 7.0.2, create tables A and B where B has a foreign
> key reference to A. Grant user X insert access on B but only
> select access on A. Attempts by X to insert into B will fail
> with an access error on A, even though X is allowed to read A
> (and thus verify that the foreign key constraint is not violated.)[B

Yes. This is a known issue due to getting row level locks
on rows in A with SELECT ... FOR UPDATE which requires update
permission (and presumably select as well). For more information,
check out the -hackers archive over the last couple of months.

The current workaround is somewhat painful, and involves giving
update permission and using a trigger to actually prevent unwanted
changes.

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message pgsql-bugs 2000-08-22 21:49:47 PostgreSQL BugTool Submission
Previous Message pgsql-bugs 2000-08-22 19:36:29 PostgreSQL BugTool Submission