public inbox for [email protected]  
help / color / mirror / Atom feed
From: Tom Lane <[email protected]>
To: Bruce Momjian <[email protected]>
Cc: David G. Johnston <[email protected]>
Cc: Pavlo Golub <[email protected]>
Cc: Laurenz Albe <[email protected]>
Cc: [email protected] <[email protected]>
Subject: Re: COPY manual is ambiguous about column list
Date: Fri, 20 Dec 2019 09:13:33 -0500
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>
	<[email protected]>
	<CAMtUEpBmq3Mefkyh=RmkC4Fuqq+YtbUrr_nHnzxUwEbwm+CPfg@mail.gmail.com>
	<[email protected]>
	<[email protected]>
	<CAKFQuwaxE-m5VKQkOapv+3kMnP2Q9hEb0NbGeBfqkQuX3UmVgQ@mail.gmail.com>
	<[email protected]>
	<CAKFQuwYHOpSfBcyX33Avt3ncrDsu6pxb-LXTm0SA+-nGWVSbhQ@mail.gmail.com>
	<[email protected]>

Bruce Momjian <[email protected]> writes:
> OK, how is this?

I do not like the phrasing of

    If a column list is
    specified in <command>COPY FROM</command>, the number and position of
    the columns must match those fields in the file.

I'm not quite sure why, but that reads to me as implying that the COPY
will identify columns of the file by name and match them up.  Or at
least it could be read that way by somebody who was predisposed to
believe it.  I'd go with something more like

    If a column list is
    specified in <command>COPY FROM</command>, only the listed columns
    are read from the file (whose fields must match the column list).

			regards, tom lane





view thread (16+ messages)  latest in thread

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: [email protected]
  Cc: [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
  Subject: Re: COPY manual is ambiguous about column list
  In-Reply-To: <[email protected]>

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

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