Re: [GENERAL] psql question: aborting a "script"

2016-03-15 Thread Francisco Olarte
Hi Melvin: On Tue, Mar 15, 2016 at 3:57 PM, Melvin Davidson wrote: > What you really want is > "ON_ERROR_STOP ... > So just > SET ON_ERROR_STOP = ON > before any other statements IIRC you are right with the variable ... BUT .. it is a psql setting, not a session setting,

Re: [GENERAL] psql question: aborting a "script"

2016-03-15 Thread Albe Laurenz
John McKown wrote: > I'm likely abusing the psql program. What I have is an awk program which > reads a file and produces a > number of INSERT INTO commands. I then feed these commands into psql to > execute them. Yes, a Perl > program would be a better idea. Anyway, sometimes the commands are

Re: [GENERAL] psql question: aborting a "script"

2016-03-15 Thread John McKown
On Tue, Mar 15, 2016 at 9:57 AM, Melvin Davidson wrote: > > > On Tue, Mar 15, 2016 at 10:49 AM, John McKown < > john.archie.mck...@gmail.com> wrote: > >> On Tue, Mar 15, 2016 at 9:38 AM, Adrian Klaver > > wrote: >> >>> On 03/15/2016 07:33 AM,

Re: [GENERAL] psql question: aborting a "script"

2016-03-15 Thread Melvin Davidson
On Tue, Mar 15, 2016 at 10:49 AM, John McKown wrote: > On Tue, Mar 15, 2016 at 9:38 AM, Adrian Klaver > wrote: > >> On 03/15/2016 07:33 AM, John McKown wrote: >> >>> I'm likely abusing the psql program. What I have is an awk program which

[GENERAL] psql question: aborting a "script"

2016-03-15 Thread John McKown
I'm likely abusing the psql program. What I have is an awk program which reads a file and produces a number of INSERT INTO commands. I then feed these commands into psql to execute them. Yes, a Perl program would be a better idea. Anyway, sometimes the commands are rejected due to some problem,