pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Yilin Zhang <jiezhilove@126.com>
To: jian he <jian.universality@gmail.com>
Cc: PostgreSQL-development <pgsql-hackers@postgresql.org>
Subject: Re: COPY FROM with RLS
Date: Tue, 28 Jul 2026 17:15:17 +0800 (CST)
Message-ID: <1266b6dc.6689.19fa801caa0.Coremail.jiezhilove@126.com> (raw)
In-Reply-To: <CACJufxHU3tetCM+Qymxpj7-OLP8b6x3HJAnARadSrEAt64MHkg@mail.gmail.com>
References: <CACJufxFbmnoa5O-vL43DPTCGt6oagY4dXgKxy=rcD9-e9g0zEg@mail.gmail.com>
	<CACJufxFdt0+R6C5ZByAK3DpMEXbb=3Hc0XyRTPvbjpc9sPt=gQ@mail.gmail.com>
	<70d4ee07.f25.19f161ce6b2.Coremail.jiezhilove@126.com>
	<CACJufxHU3tetCM+Qymxpj7-OLP8b6x3HJAnARadSrEAt64MHkg@mail.gmail.com>

At 2026-07-13 16:13:58, "jian he" <jian.universality@gmail.com> wrote:
>Hi.
>While v2 has extensive failure test cases, it doesn't have a single
>successful test case,
>that's why this issue wasn't found.
>The 2 issues you reported are fixed in the attached v3.
>
>Also, previously in v2:
>+COPY r1 FROM STDIN WITH (DELIMITER ','); -- fail
>+ERROR:  new row violates row-level security policy "p2" for table "r1"
>+CONTEXT:  COPY r1, line 1: "4"
>
>it's better to remove the CONTEXT line.
>because ExecWithCheckOptions has comments like:
>/*
> * For WITH CHECK OPTIONs coming from views, we might be
> * able to provide the details on the row, depending on
> * the permissions on the relation (that is, if the user
> * could view it directly anyway).  For RLS violations, we
> * don't include the data since we don't know if the user
> * should be able to view the tuple as that depends on the
> * USING policy.
> */



Hi,
I have reviewed the latest version of the patch, LGTM.


Best regards,

--

Yilin Zhang

view thread (11+ messages)  latest in thread

Message-ID: <1266b6dc.6689.19fa801caa0.Coremail.jiezhilove@126.com>
Permalink:  ../1266b6dc.6689.19fa801caa0.Coremail.jiezhilove@126.com/
Also on:    postgresql.org/message-id/1266b6dc.6689.19fa801caa0.Coremail.jiezhilove@126.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: jiezhilove@126.com, jian.universality@gmail.com
  Subject: Re: COPY FROM with RLS
  In-Reply-To: <1266b6dc.6689.19fa801caa0.Coremail.jiezhilove@126.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox