Re: copy command - something not found

From: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
To: susan(dot)hurst(at)brookhurstdata(dot)com, pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Re: copy command - something not found
Date: 2020-12-29 20:43:39
Message-ID: 3111aa28-2211-c2ce-8488-7de244d41b27@aklaver.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 12/29/20 12:01 PM, Susan Hurst wrote:
> Actually, the -c was in an example of a copy command that I found while
> working at my last job. I tried executing the command without the -c and
> got the same results as before, so I suppose I really don't know what it
> means.
>
> Can you enlighten me?

-c is for a command string and if I am following <
${CSVPATH}copycmd.z(tmp) is a redirect of a file.

It will help to know what is actually in the file?

>
> ---
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> Susan E Hurst
> Principal Consultant
> Brookhurst Data LLC
> Email: susan(dot)hurst(at)brookhurstdata(dot)com
> Mobile: 314-486-3261
>
> On 2020-12-29 13:23, David G. Johnston wrote:
>
>>
>> On Tuesday, December 29, 2020, Susan Hurst
>> <susan(dot)hurst(at)brookhurstdata(dot)com
>> <mailto:susan(dot)hurst(at)brookhurstdata(dot)com>> wrote:
>>
>>
>> ##-- shell script command
>> psql -c < ${CSVPATH}copycmd.z
>>
>> Given the meaning of ā€œ-cā€ what are you expecting that to do?
>> David J.

--
Adrian Klaver
adrian(dot)klaver(at)aklaver(dot)com

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Susan Hurst 2020-12-29 20:53:09 Re: copy command - something not found
Previous Message Christophe Pettus 2020-12-29 20:43:04 Re: copy command - something not found