| From: | fi94te02(at)fi(dot)usj(dot)edu(dot)lb |
|---|---|
| To: | pgsql-php(at)postgresql(dot)org |
| Subject: | HELP!!!! UNICODE problem |
| Date: | 2004-04-26 08:39:14 |
| Message-ID: | 34998.193.95.31.157.1082968754.squirrel@fi.usj.edu.lb |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-php |
Hello,
I am using postgresql and PHP to develop an application supporting
English/French/Arabic Data. I am using PHP5RC1 and Postgresql 7.4.2
When the user enters french caracters (é,è,...) I get the following error.
====================
Warning: pg_query() [function.pg-query]: Query failed: ERROR: invalid
byte sequence for encoding "UNICODE": 0xe96d61 in
/usr/local/apache2/htdocs/Classes/DBAdapter.class.php on line 27
====================
I managed to save my SQL string into a file. When open with vi, the file reads
==============
update classe set code='MATE',description='Mathématiques
Elémentaires',cycle='SEC',classesuperieure=NULL,info=NULL where code='MATE'
~
==============
whereas the command cat shows
==============
update classe set code='MATE',description='Math�matiques El�mentaires',cycle
='SEC',classesuperieure=NULL,info=NULL where code='MATE'
==============
I tried to figure out what to do; when I copy and paste the content of the
file into the "psql" tool, it works perfectly and I can see the accented
letters in my browser; whereas the psql's command "\i <filename>" generates
the same.
Any help would be appreciated
Regards
Dani Mezher
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Christopher Kings-Lynne | 2004-04-27 02:44:43 | Re: HELP!!!! UNICODE problem |
| Previous Message | Ramesh Patel | 2004-04-26 05:28:10 | subscribe |