Re: COPY FROM WHEN condition - Mailing list pgsql-hackers

From Corey Huinker
Subject Re: COPY FROM WHEN condition
Date
Msg-id CADkLM=cXsL20mMR2aXgxmhzn6Hi2SM7xGXMAqLU_2Mu_ubY_9A@mail.gmail.com
Whole thread Raw
In response to Re: COPY FROM WHEN condition  (David Fetter <david@fetter.org>)
List pgsql-hackers

> SELECT x.a, sum(x.b)
> FROM ( COPY INLINE '/path/to/foo.txt' FORMAT CSV ) as x( a integer, b numeric, c text, d date, e json) )

Apologies for bike-shedding, but wouldn't the following be a better
fit with the current COPY?

    COPY t(a integer, b numeric, c text, d date, e json) FROM '/path/to/foo.txt' WITH (FORMAT CSV, INLINE)

+1 Very much a better fit.

pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: pgbench -M option can be specified more than once
Next
From: Tom Lane
Date:
Subject: Re: pgbench -M option can be specified more than once