SQL/MX Programming Manual for Java

SQLJ Programming
HP NonStop SQL/MX Programming Manual for Java523726-003
3-47
Specifying National Character String Literals
Specifying National Character String Literals
Specify national character string literals by using the N prefix:
These string literals are associated with the NATIONAL_CHARSET default attribute.
The NATIONAL_CHARSET setting must match the character set of the corresponding
SQL column.
When you process the SQLJ source file, the character set assigned to national
character string literals is based on the setting of NATIONAL_CHARSET in SQL/MX. In
SQL/MX Release 2.x, NATIONAL_CHARSET is UCS2 by default and is set during the
installation of SQL/MX. For more information, see the SQL/MX Installation and
Management Guide.
#sql {INSERT INTO dept_internatl
(deptnum, deptname, manager, rptdept, location)
VALUES (:deptNum, :deptName, :manager, :rptDept,
N' ')};