User Guide
SAP AG November 2002
Column definition Result
CHAR (n) UNICODE
UNICODE column
CHAR (n)
UNICODE column
CHAR (n) ASCII
ASCII column
CHAR (n) BYTE
Code neutral, i.e. the column values are not converted by
the database system
For information on setting database parameters, see the following documentation:
• Database Manager GUI: SAP DB 7.4, Section Displaying and Changing Current
Database Parameters [See SAP DB Library]
• Database Manager CLI: SAP DB 7.4, Section Changing the Value of a Database
Parameter [See SAP DB Library]
UNICODE and SQL
UNICODE can be used for metadata, application data and in SQL statements if installation of
a UNICODE-enabled database [Page 91] has been carried out.
UNICODE for metadata
If the database is UNICODE-enabled, all columns in the system tables that can be used to
request the metadata have a data type with the code attribute [See SAP DB Library]
UNICODE.
UNICODE for application data
To make application data UNICODE-enabled, you must set the UNICODE code attribute
[Page 92] in a UNICODE-enabled database for the required application data. The UNICODE
[Page 152] code attribute can be used for the data types CHAR[ACTER] (n), VARCHAR (n)
and LONG[VARCHAR]:
• CHAR[ACTER] (n) UNICODE
• VARCHAR (n) UNICODE
• LONG[VARCHAR] UNICODE
Example 1 [Page
94] illustrates the definition of Java class TableDef. Java class TableDef
can be used to display the results of various column definitions.
Displaying the Column Definition of a Table
java TableDef <jdbcurl> <table_name>
Creating a temporary table using the determined column definitions, and displaying
these column definitions
<command> ::= java TableDef <jdbcurl> <table_name>
<column_definition>
<jdbcurl> ::=
jdbc:sapdb:<database_name>?user=<userid>&password=<password>
User Manual: SAP DB 93










