Pro*C Character set problems

From: Richard Lister <pbsis_at_hotmail.com>
Date: 31 Aug 2001 05:57:13 -0700
Message-ID: <4e0a7502.0108310457.4160f279_at_posting.google.com>



[Quoted] We are modifying a system that uses Oracle Pro*C to read large text strings from Oracle 8 CLOB columns.

The system currently only stores ASCII characters (codes 0 - 127).

We have a required to store extended characters (128-255).

Our database is configured with the ISO-8859-1 (Latin-1) character set which does have extended characters (160-255).

We have managed to successfully insert characters with codes of 128, 149 and 163 into the CLOB using SQL*Plus / TOAD, but when we attempt to retrieve this CLOB into a Pro*C Char variable, the 128 and 149 characters have been converted into the '?' character and the 163 character has been converted into a '#'.

[Quoted] It would appear that despite the database's character set configuration, our Pro*C program is only configured to support the basic ASCII character set and when we retrieve data from the CLOB, any extended characters are converted to an appropriate ASCII value. The 163 is a £ sign that would explain why it is converted to # unlike the two unknown characters that are converted to '?'.

Does anybody know how to configure the character set that Pro*C uses when communicating with the Oracle 8 database?

I cannot find anything relating to this in the documentation. Perhaps it is taking the character set configuration from somewhere else such as the operating system?

Any help would be greatly appreciated.

Thanks

Richard Lister Received on Fri Aug 31 2001 - 14:57:13 CEST

Original text of this message