Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> getting NCHAR data into our database
Is anyone out there running a database that stores NCHAR data in a different character set than the overall character set? If so, please help me out here.
Recently we decided that our testing database needed to store NCHAR and NVARCHAR data in a UTF8 national character set. The database was built with US7ASCII character set. I did ALTER DATABASE SET NATIONAL CHARACTERSET "UTF8" (etc), and the data is being stored and read correctly.
The question is: How do you get fresh NCHAR data into the database when the character set != the national character set? The Oracle NLS documentation says, "Because SQL text such as the literals in SQL statements can only be represented by the database character set, and not the NCHAR character set, you should choose an NCHAR character set that either has an equivalent or subset character repertoire of the database character set." That is, we cannot input UTF8 literals into the database (either through SQL*Plus or through SQL statements passed by the application we're testing).
Now I -know- there must be people out there who use a different NATIONAL CHARACTER SET than their CHARACTER SET -- otherwise what's the point of having NCHAR data at all? So there -must- be a way to get fresh NCHAR data into our tables. The question is, how the heck do you do it???
At the moment, the only solution we've come up with is to put the UTF data into a flat file and import it using SQL*Loader. Yuck, yuck, uuugly. Please, post and let me know what the "standard" way is, or how you've been doing it.
TIA,
Natalka Roshak
-- He stands proud in his uniform He knows he's made it now He's been told he'll be a hero But he hasn't been told how He receives his plastic key to heaven Takes his holy vow Then he turns, Then he's gone --Peter Ulrich, "Taqaharu's Leaving"Received on Thu Mar 02 2000 - 00:00:00 CST
![]() |
![]() |