From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | adrian(dot)klaver(at)gmail(dot)com |
Cc: | pgsql-general(at)postgresql(dot)org, Vick Khera <vivek(at)khera(dot)org>, Borek Lupomesky <borek(at)lupomesky(dot)cz> |
Subject: | Re: Permission denied when inserting |
Date: | 2011-02-28 17:15:27 |
Message-ID: | 19987.1298913327@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Adrian Klaver <adrian(dot)klaver(at)gmail(dot)com> writes:
> I understand, yet I don't:) Seems I have a misconception of the the
> FOREIGN KEY process. The error was on the query below, which I am
> taking is the query you refer to above. To me it looks like a look up
> from the referencing(permout) table to the referenced(out2cp) one. The
> part I am not clear on is why that runs with the permissions of the
> referenced table not the referencing table?
Because we force it that way so that you don't have to splatter
permissions all around to support a foreign key check. Generally
the internal FK check queries will only fail if the owner of a table
revokes his own permissions, which isn't too usual.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Adrian Klaver | 2011-02-28 17:20:46 | Re: Permission denied when inserting |
Previous Message | Adrian Klaver | 2011-02-28 17:06:05 | Re: Permission denied when inserting |