Unicode and Code Page Support
Total Page:16
File Type:pdf, Size:1020Kb
Natural Unicode and Code Page Support Version 8.2.4 November 2016 This document applies to Natural Version 8.2.4. Specifications contained herein are subject to change and these changes will be reported in subsequent release notes or new editions. Copyright © 1979-2016 Software AG, Darmstadt, Germany and/or Software AG USA, Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors. The name Software AG and all Software AG product names are either trademarks or registered trademarks of Software AG and/or Software AG USA, Inc. and/or its subsidiaries and/or its affiliates and/or their licensors. Other company and product names mentioned herein may be trademarks of their respective owners. Detailed information on trademarks and patents owned by Software AG and/or its subsidiaries is located at http://softwareag.com/licenses. Use of this software is subject to adherence to Software AG's licensing conditions and terms. These terms are part of the product documentation, located at http://softwareag.com/licenses/ and/or in the root installation directory of the licensed product(s). This software may include portions of third-party products. For third-party copyright notices, license terms, additional rights or re- strictions, please refer to "License Texts, Copyright Notices and Disclaimers of Third-Party Products". For certain specific third-party license restrictions, please refer to section E of the Legal Notices available under "License Terms and Conditions for Use of Software AG Products / Copyright and Trademark Notices of Software AG Products". These documents are part of the product documentation, located at http://softwareag.com/licenses and/or in the root installation directory of the licensed product(s). Use, reproduction, transfer, publication or disclosure is prohibited except as specifically provided for in your License Agreement with Software AG. Document ID: NATMF-NNATUNICODE-824-20161107 Table of Contents Preface ................................................................................................................................ v 1 Introduction ..................................................................................................................... 1 About Code Pages and Unicode ................................................................................ 2 About Unicode and Code Page Support in Natural .................................................. 3 2 Enabling Unicode and Code Page Support ..................................................................... 5 International Components for Unicode for Software AG (ICS) ................................ 6 ICS Module SAGICU ................................................................................................. 6 Alternative ICS Modules for Support of Architecture Levels ................................... 8 ICU Data Libraries ..................................................................................................... 9 Unicode and Code Page Support for Adabas ............................................................ 9 Translation Tables ..................................................................................................... 10 Support of Multi-Byte Code Pages ........................................................................... 10 3 Configuration and Administration of the Unicode/Code Page Environment .............. 11 Customizing the ICU Data Library .......................................................................... 12 Profile Parameters and Macros ................................................................................ 15 Encoding Information .............................................................................................. 20 4 Development Environment ........................................................................................... 21 Development Environment ...................................................................................... 22 Customizing Your Environment .............................................................................. 23 Editors in the SPoD Environment ............................................................................ 23 Code Page Support for Editors, System Commands and Utilities .......................... 24 Code Page Support for Natural Source Objects ....................................................... 26 5 Unicode and Code Page Support in the Natural Programming Language .................. 29 Natural Data Format U for Unicode-Based Data ..................................................... 30 Statements ................................................................................................................ 31 Logical Condition Criteria ....................................................................................... 35 System Variables ...................................................................................................... 36 Large and Dynamic Variables .................................................................................. 36 Session Parameters ................................................................................................... 36 Sample Programs ..................................................................................................... 39 6 Unicode Input/Output Handling in Natural Applications ........................................... 41 Displaying and Entering Unicode Data ................................................................... 42 Natural Web I/O Interface Client ............................................................................. 42 7 Bidirectional Language Support ................................................................................... 47 General Information ................................................................................................. 48 Screen Direction ....................................................................................................... 48 Field Direction .......................................................................................................... 48 Arabic Shaping ......................................................................................................... 50 8 Unicode Data Storage .................................................................................................... 53 Unicode Data/Parameter Access .............................................................................. 54 Database Management System Interfaces ................................................................ 54 Work Files and Print Files ........................................................................................ 55 9 Migrating Existing Applications ................................................................................... 57 iii Unicode and Code Page Support Impact of Unicode on Existing Applications ........................................................... 58 Migrating Existing Objects ....................................................................................... 58 Adding Unicode Support to Existing Applications ................................................. 60 Migrating Natural Remote Procedure Calls (RPC) .................................................. 60 10 Frequently Asked Questions ....................................................................................... 61 Why do I get the startup error "Invalid code page specified"? ................................ 62 What is the "default code page"? .............................................................................. 62 What default code page is used? .............................................................................. 62 How can I display all relevant Natural code page settings? .................................... 62 How can I handle UTF-8 encoding with Natural code? .......................................... 62 Why are some characters not displayed correctly? .................................................. 63 Why do I get an error when I want to edit a Natural source? ................................. 63 Why do I get an error when I want to save a Natural source? ................................ 63 How can I find out the encoding of a Natural source? ............................................ 63 How can I change the encoding of a Natural source? ............................................. 64 Which substitution character is used if a character cannot be converted? .............. 64 Can I use Natural sources with previous Natural versions that are not code page enabled? .................................................................................................................... 64 Index ................................................................................................................................. 65 iv Unicode and Code Page Support Preface This documentation describes how Natural supports Unicode and code pages on mainframe platforms. It also describes how Natural supports bidirectional languages. This documentation is organized under the following headings: Introduction General information on code pages and the Unicode Standard, and on how Unicode and code pages are supported in Natural. Enabling Unicode and Code Page Information on International Components for Unicode for Software Support AG (ICS), ICU data libraries, support of code pages, and on transaction tables. Configuration and Administration Information on profile parameters which provide Unicode and code