| Debbie 2006-10-17, 3:55 am |
| I am using Net Express COBOL 4.0 / Window 20003
database definition -
staff_id char(12)
staff_surname nchar(40)
staff_forename nchar(40)
where staff_id contains 416001669
and the staff_surname contains 3 russian cahracter the first is
unistr('\0416')
code -
02 L-sucf-STAFF-ID
pic X(12).
02 L-sucf-STAFF-SURNAME-NCHAR
* pic N(020) USAGE IS NATIONAL
..
pic N(020)
..
02 L-sucf-STAFF-FORENAME-NCHAR
* pic N(20) USAGE IS NATIONAL
..
pic N(20)
..
exec sql
select
STAFF_ID,
STAFF_SURNAME,
STAFF_FORENAME
into
:L-sucf-staff-id,
:L-sucf-staff-surname-nchar,
:L-sucf-staff-forename-nchar
from
SPPTB_snaf
where
STAFF_ID = :L-sucf-staff-id
end-exec
The Oracle 9i pre compiler pro*cob fails when 'usage is national' is
specified, without it the nchar characters are translated to the
nearest ascii.
I have also tried connecting to the database with an ODBC driver where
again the unicode is translated. I need to be able to process the
unicode data myself.
Frederico Fonseca wrote:
> On 16 Oct 2006 01:57:44 -0700, "Debbie"
> <debbie.burton@workplacesystems.com> wrote:
>
>
>
> Which COBOL Compiler and Version, and OS used.
>
> Also please post your code, just the enough to see variable
> declaration and a single SELECT that ilustrates the problem.
> And some sample data also.
>
>
>
> Frederico Fonseca
> ema il: frederico_fonseca at syssoft-int.com
|