|
Oracle® Database Globalization Development Kit Java API Reference 11g Release 1 (11.1) Book Part Number B28299-01 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
oracle.i18n.util.OraSQLUtil
public class OraSQLUtil
The OraSQLUtil class is an Oracle SQL utility class.
The following functionality is available in this class:
\[0-9A-Z]{4}, for the UNISTR function| Method Summary | |
|---|---|
static String |
escapeUNISTR(String str, String dbCharset)Escapes the string into UNISTR form if the character is not supported by the database character set. |
static boolean |
isValidIdentifier(String srcstr, String dbCharset)Checks if the string is valid in the database character set. |
static boolean |
synchronizeLocale(Locale locale, Connection con)Synchronizes the session NLS parameters with the locale. |
static boolean |
synchronizeLocale(String oralanguage, String oraterritory, Connection con)Synchronizes the database session NLS parameters with the Oracle language and territory names. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static boolean isValidIdentifier(String srcstr,
String dbCharset)
throws UnsupportedEncodingException
srcstr - a string to be examineddbCharset - Oracle database character set nametrue if the data is valid in the database character set, otherwise falseUnsupportedEncodingException - if the dbCharset parameter is invalid
public static String escapeUNISTR(String str,
String dbCharset)
throws UnsupportedEncodingException
UNISTR form if the character is not supported by the database character set.str - a string to be examineddbCharset - Oracle database character set nameUNISTR string containing Unicode escaped form if the character is not supported by the character setUnsupportedEncodingException - if the dbCharset parameter is invalid
public static boolean synchronizeLocale(Locale locale,
Connection con)
throws SQLException
This executes ALTER SESSION SQL commands to set NLS session parameters to synchronize the locale and attributes in this object. The following session parameters are updated:
locale - Java locale objectcon - database connectiontrue if successful, otherwise falseSQLException - if a SQL exception occurs
public static boolean synchronizeLocale(String oralanguage,
String oraterritory,
Connection con)
throws SQLException
This executes ALTER SESSION SQL commands to set NLS session parameters to synchronize the locale and attributes in this object. The following session parameters are updated:
oralanguage - Oracle language nameoraterritory - Oracle territory namecon - database connectiontrue if successful, otherwise falseSQLException - if a SQL exception occurs
|
Oracle® Database Globalization Development Kit Java API Reference 11g Release 1 (11.1) Book Part Number B28299-01 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||