Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: oracle table insert: french accent
On 21 Jul 2003 20:24:58 -0700, pssoft7_at_hotmail.com (Simonz) wrote:
>Hi, there.
>
>I have read many postings about character sets and database support
>for multibyte.
>I came to conclusion that by setting database's character set to UTF8
>or WE8ISO8859P1 I would be able to INSERT into my tables, data with
>french accents.
>I set my environment variable (UNIX) LANG=fr and launch SQL*Plus,
>connect to Oracle database and tried this:
>
>----- cut -----
>SQL> CREATE TABLE try_one (my_name nvarchar2(10));
>
>Table created.
>
>SQL> INSERT INTO try_one VALUES ('vhicule');
>INSERT INTO try_one VALUES ('vhicule')
> *
>ERROR at line 1:
>ORA-12704: character set mismatch
>
>----- cut -----
>
>PS: the 'vhicule' is actually 'vehicule' with french e (with an
>accent).
>
>I have no idea of what wrong with this. could anybody please give me
>some clue or hints? I have searched web sites using googles in either
>web sites or newsgroups with no clues.
>
>Thanks in advance.
>
>Simonz
As your column is a *n*varchar2, you need to prefix N before the
'vehicule' string.
You also need to set NLS_LANG (to FRENCH_FRANCE.WE8ISO8859P1 (or
preferably P15 if you want to support the euro sign, but for that you
will need to change the database characterset. As P15 is not a
superset of P1, you'll need to recreate the database)
Sybrand Bakker, Senior Oracle DBA
To reply remove -verwijderdit from my e-mail address Received on Mon Jul 21 2003 - 22:57:50 CDT