X-Original-To: pgsql-general-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [64.117.224.130]) by svr1.postgresql.org (Postfix) with ESMTP id 60D25D1C9D1 for ; Thu, 14 Aug 2003 03:46:56 +0000 (GMT) Received: from svr1.postgresql.org ([64.117.224.193]) by localhost (neptune.hub.org [64.117.224.130]) (amavisd-new, port 10024) with ESMTP id 49192-03 for ; Thu, 14 Aug 2003 00:45:16 -0300 (ADT) Received: from ohio.stageserver.net (ohio.stageserver.net [216.180.225.74]) by svr1.postgresql.org (Postfix) with ESMTP id 5D837D1CA28 for ; Thu, 14 Aug 2003 00:45:55 -0300 (ADT) Received: from ip68-6-45-108.sb.sd.cox.net ([68.6.45.108] helo=localhost.localdomain) by ohio.stageserver.net with esmtp (TLSv1:DES-CBC3-SHA:168) (Exim 4.20) id 19n93l-0007R9-VO for pgsql-general@postgresql.org; Wed, 13 Aug 2003 22:45:58 -0500 Date: Wed, 13 Aug 2003 20:45:55 -0700 From: expect To: pgsql-general@postgresql.org Subject: Re: importing db as text files Message-Id: <20030813204555.755edd6b.expect@ihubbell.com> In-Reply-To: <20030813213004.GA27062@wolff.to> References: <20030813141420.1db05267.expect@ihubbell.com> <20030813213004.GA27062@wolff.to> Organization: iHubbell X-Mailer: Sylpheed version 0.9.4claws (GTK+ 1.2.10; i686-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - ohio.stageserver.net X-AntiAbuse: Original Domain - postgresql.org X-AntiAbuse: Originator/Caller UID/GID - [0 0] / [47 12] X-AntiAbuse: Sender Address Domain - ihubbell.com X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200308/663 X-Sequence-Number: 47080 On Wed, 13 Aug 2003 16:30:04 -0500 Bruno Wolff III wrote: > On Wed, Aug 13, 2003 at 14:14:20 -0700, > expect wrote: > > > > What's the big deal with importing text files? I have a 70 MB file to import > > and it's been one problem after another. I used the copy command and it appears > > that it's just not possible. I finally massaged the file into a .sql file and > > That is unlikely, but without more details it is hard to say what you need > to do. What's unlikely? That it didn't work? But it didn't work. > > > ran that using \i db.sql but that failed too because I overlooked ' in names > > like D'Adario. The other problem I encountered was that a numeric field had > > to have data in it, pg would not default to the default value. So instead of > > You can use the keyword default in insert statements to get a default value.