以 UNICODE 显示整个 ORACLE 8 位字符集
我根据八位字符集 Oracle 数据库维护一个 Java EE Web 应用程序。
该应用程序将在国外使用,我希望能够检查字符串 - 例如使用 UNICODE 正则表达式,以及来自 Java 和 Javascript 的字符串 - 以查看它们是否适合数据库 CHARSET。
GDK(全球化开发工具包)中的一个函数给出了 oracle 字符集的等效 Java 名称(我认为它是 ISO-8859-15)。但我不确定对应关系是否准确。
我想要的是显示整个字符集 - 不是 ISO...,而是 ORACLE 一个字符一个字符地使用 Java 和 Javascript,甚至显示 UNICODE 点并区分控制字符和可打印字符。
Oracle的GDK中有一个函数可以达到这个目的吗?
谢谢。
I maintain an Java EE web application against an eight bits charset oracle database.
The application will be used from abroad and I want to be able to check strings -for example with UNICODE regexps, and both from Java and from Javascript- to see if they fit into the database CHARSET.
One function in GDK -globalization developer kit- gives the equivalent Java name of the oracle charset -I think it was ISO-8859-15-. But I'm not certain the correspondence will be exact.
What I wanted is to display the whole charset -NOT ISO..., but the ORACLE one- char by char to use both from Java and Javascript, even to display the UNICODE points and to tell apart the control characters from printable ones.
There is a funcion in Oracle's GDK to that end?
Thank you.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我想我已经找到了! (尤里卡!)
一个小的 JAVA JDBC 程序产生了 ISO-8859-15 中与 ISO-8859-1 不同的字符(顺便说一句,我了解到 ISO-8859-1 占用从 0x00 到 0xff 的字符)统一码)。
程序输出:
CHR: 164 UNICODE: 8364 欧元符号
CHR: 166 UNICODE: 352
CHR: 168 UNICODE: 353
CHR: 180 UNICODE: 381
CHR: 184
UNICODE: 382 CHR: 188 UNICODE: 338
CHR: 189 UNICODE: 339
CHR: 190统一码: 376
程序代码(根本不使用 GDK):
注意:语句“SELECT CHR(i using nchar_cs) FROM DUAL”只是返回相同的数字...为什么?
I think I've found it! (Eureka!)
A little JAVA JDBC program resulted in exactly the characters in ISO-8859-15 that are distintc to ISO-8859-1 (by the way, I've learned that ISO-8859-1 occupies from 0x00 to 0xff in UNICODE).
Program output:
CHR: 164 UNICODE: 8364 euro sign
CHR: 166 UNICODE: 352
CHR: 168 UNICODE: 353
CHR: 180 UNICODE: 381
CHR: 184 UNICODE: 382
CHR: 188 UNICODE: 338
CHR: 189 UNICODE: 339
CHR: 190 UNICODE: 376
Program code (not using GDK at all):
NOTE: the statement "SELECT CHR(i using nchar_cs) FROM DUAL" just gave back the same numbers... WHY?