Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Oracle 10G - character sets.

Re: Oracle 10G - character sets.

From: markpapadakis <markpapadakis_at_gmail.com>
Date: 8 Jan 2007 03:25:12 -0800
Message-ID: <1168255511.751352.226130@q40g2000cwq.googlegroups.com>

Thank you for replying, Laurenz

>
> What exactly do you mean by 'omegas'?
> Do you mean the greek character with UNICODE code point 0x03A9 or 0x03C9
> or are you referring to the five-character string 'omega'?

Omegas are 'Ώ'. That is, not the five character string.

>
> > The rows are in WE8MSWIN1252 encoding - setting NLS_LANG to
> > GREEK_GREECE.EL8ISO8859P works just fine with sqlplus. However, it
> > doesn't with my clients ( PHP and C ). Using different NLS_LANG
> > combinations seem to make a difference, yet I am still getting charset
> > conversion issues.
>
> There is no EL8ISO8859P, (Greek would be EL8ISO8859P7).
> Maybe your problem is a typo really.
>

The typo occurred when I was typing the message - I meant to say 'EL8ISO8859P7'. I am sorry about that.

> On the other hand, if you are trying to store greek characters in a
> database, WE8MSWIN1252 is the wrong database character set for you
> because there are no greek letters in this codepage (the exception being
> "mu", used as "micro" sign, which is UNICODE 0x00B5).
>

nls_database_parameters.NLS_CHARACTERSET is 'WE8MSWIN1252'. If I set NLS_LANG properly (i.e export
NLS_LANG=GREEK_GREECE.EL8ISO8859P7 ) and run sqlplus, retrieving the rows (i.e SELECT columnNames from TABLE ) works just fine - I get the data back in greek.

Both clients seem to acknowledge the fact that NLS_LANG is defined, for I get different output depending on the value of the NLS_LANG env.variable, however, instead of Greek characters I get either '?' or the 'omega' character I mentioned above. It is as if sqlplus is performing an additional step when it retrieves the rows - a step I may be missing.

> Can you be more detailed on the following points:
>
> - What is your operating system and Oracle version?
Redhat Linux, ES 3
Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production

> - What is the system character set when you run
> a) SQL*Plus

GREEK_GREECE.EL8ISO8859P7
> b) PHP

GREEK_GREECE.EL8ISO8859P7
> - What is your database character set?
By that, I assume you mean nls_database_parameters.NLS_CHARACTERSET, which is == "WE8MSWIN1252"

> - What was the database character set of the database from which the
> export files originate?

According to import:

import done in US7ASCII character set and AL16UTF16 NCHAR character set import server uses WE8MSWIN1252 character set (possible charset conversion)
export client uses EL8ISO8859P7 character set (possible charset conversion)

> - What characters cause problems for you?
All greek characters for both PHP and C++ client. Work perfectly with sqlplus

> - What is the exact setting of NLS_LANG when
> a) things look right with SQL*Plus

GREEK_GREECE.EL8ISO8859P7 ( or any other territory and language combination, as long as the charset portion is == "EL8ISO8859P7 " )

> b) things look wrong with SQL*Plus

Any other charset value other than "EL8ISO8859P7"

> c) things look wrong with PHP

GREEK_GREECE.EL8ISO8859P7 or basically any other possible value.

> - What exactly do you get instead of the problem characters when it is
> NOT a question mark?
>

When I use LANG_TERRITORY.UTF8 ( or specify it explicitly using OCIEnvNlsCreate() ), I get something like: ΒΏeΒΏΒΏsΒΏΒΏΒΏΒΏΒΏΒΏ stΒΏΒΏ ΒΏΒΏΒΏΒΏpΒΏ

Thank you very much,
Mark

> Yours,
> Laurenz Albe
Received on Mon Jan 08 2007 - 05:25:12 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US