Restore Data Encountered the ERROR: literal carriage return found in data Error

From: "Wang, Mary Y" <mary(dot)y(dot)wang(at)boeing(dot)com>
To: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Restore Data Encountered the ERROR: literal carriage return found in data Error
Date: 2010-03-04 23:52:45
Message-ID: FA20D4C4FEBFD148B1C0CB09913825FC01EBE7D0CF@XCH-SW-06V.sw.nos.boeing.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi All,

After a pg_dumpall, I'm trying to restore with psql -e template1 -f 21.bak &>/tmp/out21.bak . I'm trying to migrate to Postgres 8.3.8.

I'm getting lots errors like this one:
"psql:21.bak:340557: ERROR: literal carriage return found in data
HINT: Use "\r" to represent carriage return."
After doing some research, one person posted here : http://forums.devshed.com/postgresql-help-21/restoring-data-from-pg-7-1-3-7-4-release-99865.html and this person said
"sed 's/^M/\\r/' alldump.sql > alldump2.sql
where ^M is entered by pressing Ctrl+V then Enter. "

I'm confused why "Ctrl+V"? I thought that is a paste function key.

Mary

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Mridula Mahadevan 2010-03-05 00:19:02 Foreign key behavior different in a function and outside
Previous Message Terry 2010-03-04 23:18:45 Re: join from multiple tables