copy with escape

From: "blackwater dev" <blackwaterdev(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: copy with escape
Date: 2008-02-26 02:20:24
Message-ID: 34a9824e0802251820s33da06bg752ccfabd4db49ea@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I have data that I'm running through pg_escape_sting in php and then adding
to stdin for a copy command. The problem is "O'reilly" is being changed to
"O''Reilly" in the string and then in the db. I saw with the copy command I
can specify the escape but it isn't working for me. Should this command fix
this double 'single' quote issue when I put it in the db? And what is the
proper syntax?

COPY mytable FROM stdin with escape

Thanks!

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2008-02-26 03:07:13 Re: copy with escape
Previous Message Tom Lane 2008-02-26 01:31:20 Re: Windows 8.3 installer leaves a debug flag on?