pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andrew Gierth <andrew@tao11.riddles.org.uk>
To: Pepe TD Vo <pepevo@yahoo.com>
Cc: Scott Ribe <scott_ribe@elevated-dev.com>
Cc: Pgsql-admin <pgsql-admin@lists.postgresql.org>
Subject: Re: insert aborted commands ignored
Date: Thu, 31 Jan 2019 21:09:18 +0000
Message-ID: <871s4sa63w.fsf@news-spur.riddles.org.uk> (raw)
In-Reply-To: <890332297.1033268.1548966904362@mail.yahoo.com>
References: <1861353148.992207.1548962087385.ref@mail.yahoo.com>
	<1861353148.992207.1548962087385@mail.yahoo.com>
	<49E280F0-7021-4FD7-AA99-985A86FA899C@elevated-dev.com>
	<2031259937.990023.1548963344432@mail.yahoo.com>
	<5D93F164-7317-43F6-B685-362779757250@elevated-dev.com>
	<729416431.1006652.1548963751866@mail.yahoo.com>
	<B83DF2D4-A966-4C64-813E-C04340D8A93F@elevated-dev.com>
	<524354657.997228.1548963965240@mail.yahoo.com>
	<3842423F-D68D-4BD3-AB34-7508B01B2A9C@elevated-dev.com>
	<1225497522.1016680.1548965545454@mail.yahoo.com>
	<8004E05B-CAFA-4620-8E10-09A796064C9B@elevated-dev.com>
	<677786735.1029265.1548966193847@mail.yahoo.com>
	<C301F965-CFAC-41D3-BE75-9D5D2F6953CE@elevated-dev.com>
	<890332297.1033268.1548966904362@mail.yahoo.com>

>>>>> "Pepe" == Pepe TD Vo <pepevo@yahoo.com> writes:

 Pepe> here how I run the script
 Pepe> $ psql -U postgres -d CIDR < insert.sql > insert_cidrmgmt.txt

psql -v ON_ERROR_STOP=1 -U postgres -d CIDR < insert.sql > insert_cidrmgmt.txt

That tells psql to stop on the first error, so you'll be able to see
what the real error was.

Your .txt file does not capture the error because you redirected only
stdout, and errors go to stderr instead.

-- 
Andrew (irc:RhodiumToad)




view thread (24+ messages)  latest in thread

Message-ID: <871s4sa63w.fsf@news-spur.riddles.org.uk>
Permalink:  ../871s4sa63w.fsf@news-spur.riddles.org.uk/
Also on:    postgresql.org/message-id/871s4sa63w.fsf@news-spur.riddles.org.uk

 · 

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: pgsql-admin@postgresql.org
  Cc: andrew@tao11.riddles.org.uk, pepevo@yahoo.com, scott_ribe@elevated-dev.com, pgsql-admin@lists.postgresql.org
  Subject: Re: insert aborted commands ignored
  In-Reply-To: <871s4sa63w.fsf@news-spur.riddles.org.uk>

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

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