Re: Add new COPY option REJECT_LIMIT - Mailing list pgsql-hackers

From jian he
Subject Re: Add new COPY option REJECT_LIMIT
Date
Msg-id CACJufxGKKSc7ctga8+2ZijHdjnKu2arxrLHqBmoF7AVysex6Cw@mail.gmail.com
Whole thread Raw
In response to Add new COPY option REJECT_LIMIT  (torikoshia <torikoshia@oss.nttdata.com>)
List pgsql-hackers
> I'm wondering if we can use the wording maxerror as in the attached
> patch.
>

+   <varlistentry>
+    <term><literal>REJECT_LIMIT</literal></term>
+    <listitem>
+     <para>
+      Specifies the maximum number of errors tolerated while converting a
+      column's input value to its data type, when
<literal>ON_ERROR</literal> is
+      set to <literal>ignore</literal>.
+      If the input causes more errors than the specified value, the
<command>COPY</command>
+      command fails, even with <literal>ON_ERROR</literal> set to
<literal>ignore</literal>.
+      This clause must be used with
<literal>ON_ERROR</literal>=<literal>ignore</literal>
+      and <replaceable class="parameter">maxerror</replaceable> must
be positive.
+      If not specified, <literal>ON_ERROR</literal>=<literal>ignore</literal>
+      allows an unlimited number of errors, meaning
<command>COPY</command> will
+      skip all erroneous data.
+     </para>
+    </listitem>
+   </varlistentry>

mentioning <replaceable class="parameter">maxerror</replaceable> is a
bigint type
or explicitly mentioning the maximum allowed value of "maxerror" would be great.

other than that, it looks good to me.



pgsql-hackers by date:

Previous
From: jian he
Date:
Subject: Re: not null constraints, again
Next
From: Maiquel Grassi
Date:
Subject: RE: Psql meta-command conninfo+