Re: pg_dump multi VALUES INSERT

From: Surafel Temesgen <surafel3000(at)gmail(dot)com>
To: David Rowley <david(dot)rowley(at)2ndquadrant(dot)com>
Cc: 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-04 08:37:09
Message-ID: CALAY4q_72PsT_awRA5S=61DJBAi1s92y1b2zM1C9Xkwf6dAW7Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox
Thread:
Lists: pgsql-hackers

On Thu, Jan 3, 2019 at 1:38 AM David Rowley <david(dot)rowley(at)2ndquadrant(dot)com>
wrote:

> On Thu, 3 Jan 2019 at 01:50, Surafel Temesgen <surafel3000(at)gmail(dot)com>
> wrote:
> > On Mon, Dec 31, 2018 at 12:38 PM David Rowley <
> david(dot)rowley(at)2ndquadrant(dot)com> wrote:
> >> Just looking at the v5 patch, it seems not to handle 0 column tables
> correctly.
>
> > The attach patch contain a fix for it
>
> + /* if it is zero-column table then we're done */
> + if (nfields == 0)
> + {
> + archputs(insertStmt->data, fout);
> + continue;
> + }
>
> So looks like you're falling back on one INSERT per row for this case.
> Given that this function is meant to be doing 'dump_inserts_multiple'
> INSERTs per row, I think the comment should give some details of why
> we can't do multi-inserts, and explain the reason for it. "we're done"
> is just not enough detail.
>
>
right , attach patch add more detail comment

regards
Surafel

Attachment Content-Type Size
multi_values_inserts_dum_v6.patch text/x-patch 11.2 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2019-01-04 09:11:38 Re: pgsql: Update ssl test certificates and keys
Previous Message Nikhil Sontakke 2019-01-04 08:35:35 Re: [HACKERS] logical decoding of two-phase transactions