X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id CA6BB3A61C8 for ; Fri, 28 Jan 2005 05:48:25 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 03390-10 for ; Fri, 28 Jan 2005 05:48:23 +0000 (GMT) Received: from tigger.fuhr.org (tigger.fuhr.org [63.214.45.158]) by svr1.postgresql.org (Postfix) with ESMTP id C275C3A61F6 for ; Fri, 28 Jan 2005 05:48:23 +0000 (GMT) Received: from winnie.fuhr.org (winnie.fuhr.org [10.1.0.1]) by tigger.fuhr.org (8.13.1/8.13.1) with ESMTP id j0S5mJHd002083 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 27 Jan 2005 22:48:21 -0700 (MST) (envelope-from mfuhr@winnie.fuhr.org) Received: from winnie.fuhr.org (localhost [127.0.0.1]) by winnie.fuhr.org (8.13.1/8.13.1) with ESMTP id j0S5mIR5099217; Thu, 27 Jan 2005 22:48:18 -0700 (MST) (envelope-from mfuhr@winnie.fuhr.org) Received: (from mfuhr@localhost) by winnie.fuhr.org (8.13.1/8.13.1/Submit) id j0S5mIxi099216; Thu, 27 Jan 2005 22:48:18 -0700 (MST) (envelope-from mfuhr) Date: Thu, 27 Jan 2005 22:48:18 -0700 From: Michael Fuhr To: Inpreet Singh Cc: pgsql-admin@postgresql.org Subject: Re: Restore postgres database problem Message-ID: <20050128054818.GA95253@winnie.fuhr.org> References: <006d01c5029a$38fb4e60$3c67a8c0@netsity.com> <20050125213847.GA95908@winnie.fuhr.org> <00bc01c50431$c3997590$3c67a8c0@netsity.com> <20050128050415.GA70681@winnie.fuhr.org> <004a01c504fa$8388e890$3c67a8c0@netsity.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <004a01c504fa$8388e890$3c67a8c0@netsity.com> X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.002 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200501/285 X-Sequence-Number: 16144 On Fri, Jan 28, 2005 at 11:00:44AM +0530, Inpreet Singh wrote: > Yes it returning carriage returns. I am pasting below the output to the > command u send to me > > *******Linux Prompt********************** > [root@localhost inpreet]# head postgres.sql | cat -v > --^M > -- PostgreSQL database cluster dump^M > --^M You could strip the carriage returns with tr, sed, perl, dos2unix, etc. Here's an example: tr -d '\r' < postgres.sql > fixed.sql # or pipe into psql What kind of system did you create the dump on? How did you transfer the file? If you can figure out how the carriage returns got there then you might be able to prevent it from happening in the future. -- Michael Fuhr http://www.fuhr.org/~mfuhr/