Oracle Thin driver string conversions
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   joro_simeonov
Posted On:   Tuesday, December 11, 2001 04:48 AM

hallo everybody,

i use oracle 8 database with US7ASCII encoding, and i use oracle thin driver to connect to it.
i have a table there columns are VARCHAR2 anf LONG.

when i use ResultSet.getString() from a VARCHAR2 column all is OK and i see french characters correct. but when i do the same with a LONG column i see wrong characters on the place of french ones. That happens because in case of VARCHAR2 and CHAR column the Thin driver converts automatically data from US7ASCII to UCS-2 (a Java string) but HOW TO CONVERT a LONG column into Java String ?
Please help if you know the answer.
bye.

Re: Oracle Thin driver string conversions

Posted By:   Bozidar_Dangubic  
Posted On:   Tuesday, December 11, 2001 06:14 AM

why don't you get from the database as long and convert it to string using Java. so first ResultSet.getLong() then String.valueOf(long).
About | Sitemap | Contact