Search Postgresql Archives

Help with ERROR: character 0xc280 of encoding "UTF8" has no equivalent in "WIN1252"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi everyone,

 

I have a database that is UTF8, and a client that is connecting using client encoding WIN1252.  There are a few records in my database that somehow have gotten characters in them that are not viewable.  When viewing the records from the command line using UTF8 client encoding there are strange looking characters, and the records cause an error when viewing under WIN1252 encoding. 

 

I cannot modify the data, so my alternative was this query, which I found an example for on a list that Google was kind enough to translate from French for me:

 

set client_encoding to 'WIN1252' ;

SELECT soldnotesid,soldid,regexp_replace(notes, E'\u008C', ' ', 'g') as notes, privatenote,modified,userloginid,notetype,sourcekey,hidden,notesmodified,notesmodifiedby,created from soldnotes where soldid<'317773002' and soldid>'317771002'

 

However, it still errors out:  psql:sql3:7: ERROR:  character 0xc280 of encoding "UTF8" has no equivalent in "WIN1252"

 

Is there any way to mask these "bad" characters from the field in a query to allow the client to work?  I'll put it in a view once I get it working so the end users can use the view.

 

PG 8.3.7. 

 

Thanks for any help you can provide. 

 

Scot Kreienkamp

 

 

 

 

This message is intended only for the individual or entity to which it is addressed.  It may contain privileged, confidential information which is exempt from disclosure under applicable laws.  If you are not the intended recipient, please note that you are strictly prohibited from disseminating or distributing this information (other than to the intended recipient) or copying this information.  If you have received this communication in error, please notify us immediately by e-mail or by telephone at the above number. Thank you.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux