Re: Add new error_action COPY ON_ERROR "log"

From: Bharath Rupireddy <bharath(dot)rupireddyforpostgres(at)gmail(dot)com>
To: Michael Paquier <michael(at)paquier(dot)xyz>
Cc: torikoshia <torikoshia(at)oss(dot)nttdata(dot)com>, "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>, jian(dot)universality(at)gmail(dot)com, Pgsql Hackers <pgsql-hackers(at)postgresql(dot)org>, Alexander Korotkov <aekorotkov(at)gmail(dot)com>
Subject: Re: Add new error_action COPY ON_ERROR "log"
Date: 2024-03-08 10:06:30
Message-ID: CALj2ACW1XUhFbvO9BO8arHGxQTHyr5cy1_csZAt6Rphvx8q1mg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Mar 7, 2024 at 12:54 PM Michael Paquier <michael(at)paquier(dot)xyz> wrote:
>
> On Thu, Mar 07, 2024 at 12:48:12PM +0530, Bharath Rupireddy wrote:
> > I'm okay with it. But, help me understand it better. We want the
> > 'log_verbosity' clause to have options 'default' and 'verbose', right?
> > And, later it can also be extended to contain all the LOG levels like
> > 'notice', 'error', 'info' , 'debugX' etc. depending on the need,
> > right?
>
> You could, or names that have some status like row_details, etc.
>
> > One more thing, how does it sound using both verbosity and verbose in
> > log_verbosity verbose something like below? Is this okay?
>
> There's some history with this pattern in psql at least with \set
> VERBOSITY verbose. For the patch, I would tend to choose these two,
> but that's as far as my opinion goes and I am OK other ideas gather
> more votes.

Please see the attached v5-0001 patch implementing LOG_VERBOSITY with
options 'default' and 'verbose'. v5-0002 adds the detailed info to
ON_ERROR 'ignore' option.

We have a CF entry https://commitfest.postgresql.org/47/4798/ for the
original idea proposed in this thread, that is, to have the ON_ERROR
'log' option. I'll probably start a new thread and add a new CF entry
in the next commitfest if there's no objection from anyone.

--
Bharath Rupireddy
PostgreSQL Contributors Team
RDS Open Source Databases
Amazon Web Services: https://aws.amazon.com

Attachment Content-Type Size
v5-0001-Add-LOG_VERBOSITY-option-to-COPY-command.patch application/octet-stream 8.8 KB
v5-0002-Add-detailed-info-when-COPY-skips-soft-errors.patch application/octet-stream 4.5 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Richard Guo 2024-03-08 10:14:00 Re: Invalid query generated by postgres_fdw with UNION ALL and ORDER BY
Previous Message Daniel Gustafsson 2024-03-08 10:05:01 Call perror on popen failure