Charset in Adabas

Dear All,

As I know there is Variable type U in Natural program to support Unicode8 or 16.

Do I need to set anything in Adabas like charset in Oracle?

The question sound stupid, but I am not familiar with Adabas

Thanks

Ray

This maps to format “W” in the Adabas FDT (the field or “column” definition, to put it in SQL terms).

More information can be found here:

http://techcommunity.softwareag.com/ecosystem/documentation/adabas/ada614unw/admin/dbuessup.htm

Hello,

Natural internally works with UTF-16 and Adabas Open Systems with UTF-8.
On Adabas Mainframe, what the application sees depends on the user encoding defined with UWCODE (default UTF-16).

I suggest to always use the OPRB parameter to ensure that the application gets Unicode fields in the correct encoding.

OPRB:(DBID=1,WCHARSET='UTF-16LE',DBID=8,WCODE=4095)

The above example shows the essential parameters:

  • access to open systems database 1, application characterset is UTF-16 little endian (e.g. for Intel386 box)

  • access to mainframe database 8, application characterset is 4095 (= UTF-16), endianness of application determined by nucleus

When planning new applications with Unicode fields the following should be considered:

  1. Adabas measures field length in bytes, Natural U fields in 2 bytes per character (e.g. WW,40,W = U20)

  2. conversion between UTF-8 and UTF-16 encodings means differing length requirements and that data stored in UTF-8 might not fit in UTF-16 field and vice versa. Suggestion: define fields lengths bigger in database and make sure application does not exceed a certain limit.

Kind regards,
Marbod Mueller