Re: COPY 'invalid byte sequence for encoding "UTF8": 0xff'

From: Steve Crawford <scrawford(at)pinpointresearch(dot)com>
To: Chris Worley <chris(dot)worley(at)timco(dot)aero>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: COPY 'invalid byte sequence for encoding "UTF8": 0xff'
Date: 2009-04-21 20:26:15
Message-ID: 49EE2BE7.2000402@pinpointresearch.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


> hmm, I was shelling out and using psql and piping the data to another
> file. Not using the dbi stuff with perl.
>
> Guess i can use a regular expression and review the link you sent me
> and escape them my self.
>
Don't *ahem* quote me on this as I haven't been using Perl for a while
but it should be something similar to:
$quoted_data = $dbh->quote($data, PG_BYTEA)

If not, I'm sure the documentation for the "quote" function will set
things straight.

Cheers,
Steve

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Christophe 2009-04-21 20:32:02 Re: Yet another "drop table vs delete" question
Previous Message Tom Lane 2009-04-21 20:20:31 Re: Yet another "drop table vs delete" question