Character set conversion when using DBMS_LOB
(Doc ID 267356.1)
Last updated on MARCH 03, 2019
Applies to:Oracle Database - Enterprise Edition - Version 188.8.131.52 to 184.108.40.206 [Release 8.0.3 to 11.2]
Oracle Database Cloud Schema Service - Version N/A and later
Oracle Database Exadata Cloud Machine - Version N/A and later
Oracle Cloud Infrastructure - Database Service - Version N/A and later
Oracle Database Cloud Exadata Service - Version N/A and later
Information in this document applies to any platform.
Document on how to load a file directly into a CLOB.
Note that we advice to use SQLdeveloper (and not sqlplus) as client when testing with UTL_FILE, this is a "know good client" that needs no NLS configuration.
You can download Sqldveloper from http://www.oracle.com/technology/products/database/sql_developer/
If the data is displayed correctly in SQLdeveloper then you are sure it's correct in the database.
It is also good to first read <Note:227531.1> Character set conversion when using UTL_FILE
The database needs to be able to STORE the characterset of the files you try to load.
If you have (for example) a file in a CL8MSWIN1251 characterset (=russian windows system) containing cyrillic then you simply cannot store it as a text/Clob field in a WE8ISO8859P1 database.
WE8ISO8859P1 cannot handle cyrillic. Here the solution is to go to a UTF8 database or to store that file as Blob .
To view full details, sign in with your My Oracle Support account.
Don't have a My Oracle Support account? Click to get started!