From: | "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com> |
---|---|
To: | Surafel Temesgen <surafel3000(at)gmail(dot)com> |
Cc: | David Rowley <david(dot)rowley(at)2ndquadrant(dot)com>, Fabien COELHO <coelho(at)cri(dot)ensmp(dot)fr>, Dmitry Dolgov <9erthalion6(at)gmail(dot)com>, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: pg_dump multi VALUES INSERT |
Date: | 2019-01-18 14:34:35 |
Message-ID: | CAKFQuwbEQpOeo3yimRDZS9q1ZmkkD5yvjGP_fCbz4LHrfRow8g@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Fri, Jan 18, 2019 at 5:02 AM Surafel Temesgen <surafel3000(at)gmail(dot)com> wrote:
> On Fri, Jan 18, 2019 at 2:29 PM David Rowley <david(dot)rowley(at)2ndquadrant(dot)com> wrote:
>>
>> On Fri, 18 Jan 2019 at 19:29, Surafel Temesgen <surafel3000(at)gmail(dot)com> wrote:
>> > this happen because i don't disallow the usage of --inserts and --rows-per-insert
>> > option together.it should be error out in those case.i correct it in attached patch
>>
>> I don't think it should be an error. It's not like the two options
>> conflict. I imagined that you'd need to specify you want --inserts and
>> optionally could control how many rows per statement that would be put
>> in those commands. I'd be surprised to be confronted with an error for
>> asking for that.
>>
>
> if you specified --inserts option you already specified the number of rows per statement which is 1 .
> if more than one rows per statement needed it must be specified using --rows-per-insert
> and specifying one row per statement using --inserts option at the same time specify
> different number of rows per statement with --rows-per-insert option seems conflicting to me.
So, the other way of looking at it - why do we even need an entirely
new option. Modify --inserts to accept an optional integer value that
defaults to 1 (I'm not sure how tricky dealing with optional option
values is though...).
--inserts-columns implies --inserts but if you want to change the
number of rows you need to specify both (or add the same optional
integer to --inserts-columns)
David J.
From | Date | Subject | |
---|---|---|---|
Next Message | David G. Johnston | 2019-01-18 14:43:01 | Re: pg_dump multi VALUES INSERT |
Previous Message | Rahila Syed | 2019-01-18 14:07:19 | Re: monitoring CREATE INDEX [CONCURRENTLY] |