|
This is part fourteen of the series that began with
What is System-Managed Storage?
What is CDRA?
CDRA is the abbreviation for Character Data Representation Architecture. It is a methodology for describing character data and certain control characters on any computer system, whether it is in ASCII, EBCDIC, single-byte, double-byte, or multiple-byte representation. This architecture fully describes the character sets and code pages registered and used throughout the world, and provides a means of simplifying the description and identification of these conventions.
Whenever you send textual (character) data, it is represented at the machine internal level by binary code--code which can vary among computer platforms and international languages. This can complicate how computer systems work together, especially in client/server scenarios where computer platforms are different, and in international network communications with multi-language configurations, where countries use different code pages.
To help ensure that character data is correctly represented and, if necessary, converted when you move data across computer platforms and international languages, DFSMS/MVS supports Character Data Representation Architecture (CDRA)/MVS.
CDRA/MVS provides a set of callable application programming interfaces (APIs) on the MVS platform. These interfaces ease the implementation of national language support and can facilitate application development, portability, and use across multiple IBM operating systems. The CDRA APIs can be used for handling character data conversion of single-byte character sets, double-byte character sets, multi-byte character sets, and the Unicode character set.
What Do I Need to Use CDRA?
The CDRA character and numeric conversion routines require IBM Language Environment support for a successful installation. You receive this support through one of the following:
- With MVS/ESA SP 5.2 or higher, use either the C/C++ language support feature of MVS/ESA SP or the Language Environment for MVS and VM program product
- With MVS/ESA SP 5.1, use either the C/C++ Language support feature of MVS/ESA SP or the LE/370 program product
- With MVS/ESA SP 4.3, use the LE/370 program product.
CDRA Attributes
DFM/MVS supports a Distributed Data Management (DDM) attribute called the Coded Character Set Identifier (CCSID). The CCSID attribute identifies the encoding scheme, character set, and code page used by the file. For example, if a file has a CCSID of 437, it is in USA ASCII format. If it has a CCSID of 297, it is in the French EBCDIC format. The meaning of each CCSID is defined in the IBM Character Data Representation Architecture.
You can set the CCSID attribute locally or remotely. On an MVS/ESA system, the IDCAMS ALTER command can be used to set the CCSID. Note that setting the CCSID attribute identifies the character set used by the file, it does not convert the file to that character set.
When you create a new MVS/ESA data set from a remote system, DFM/MVS allows you to assign a CCSID to it. If the MVS/ESA data set already exists, DFM/MVS also allows you to modify the CCSID from a remote system. You can assign a CCSID to any SMS-managed data set supported by DFM/MVS, with the exception of a partitioned data set (PDS).
DFM/MVS creates associated DDM attributes when it creates new data sets or changes the attributes of existing data sets. When copying, moving, or backing up data sets that have associated DDM attributes, it is important that you use recommended data-moving utilities or the attributes may not be preserved.
You can use one of the following tools to determine whether a data set has associated DDM attributes and what the value of the CCSID attribute is:
- ISMF Data Set List application
- IDCAMS DCOLLECT command
- IDCAMS LISTCAT command.
Data Conversion
DFM/MVS supports data conversion for stream files in single-byte code pages, but does not provide data conversion services for record files or stream files with multiple-byte character representation. When DFM/MVS stores record files on MVS/ESA, the data is stored in the format sent by the source. If a target system application requires a different data format, data conversion can be done by a source application.
For example, if record data is sent from an OS/2 source system in ASCII format, it requires conversion to EBCDIC before it can be read by a standard MVS application. This conversion from ASCII to EBCDIC can be done by the conversion utility provided by the Distributed FileManager component of SMARTdata UTILITIES.
CDRA APIs
The CDRA routines can be called from any language that supports LE/370. The CDRA API routines reside in the callable system services library, SYS1.CSSLIB. The following CDRA APIs are included in the DFSMS product library.
CDRA APIs
| API |
Description |
| CDRGESP |
Get encoding scheme, character set, and code page elements |
| CDRSCSP |
Get short form (CCSID) from specified encoding scheme (character set, code page) |
| CDRGESE |
Get encoding scheme element and its subelements |
| CDRGCTL |
Get control function definition |
| CDRSMXC |
Get short form (CCSID) with maximal character set for specified encoding scheme, code page |
| CDRMSCI |
Multiple-step convert initialize |
| CDRMSCP |
Multiple-step convert perform |
| CDRMSCC |
Multiple-step convert clean up |
| CDRXSRF |
Extract status and reason codes from feedback code |
In Summary
CDRA/MVS and DFM/MVS provide you with the ability to associate Coded Character Set Identifiers (CCSIDs) with system-managed data sets. Using CCSIDs and the APIs provided by CDRA/MVS, you can exchange data between computer systems across a variety of platforms and ensure that the data will always be represented correctly.
For additional information on CDRA, see
CDRA Reference.
[
Previous Article |
All Articles ]
|