Zoned-Decimal
来源:互联网 发布:战龙三国五行进阶数据 编辑:程序博客网 时间:2024/04/26 09:36
ILE RPG Reference
Zoned-Decimal Format
Zoned-decimal format means that each byte of storage can contain one digit or one character. In the zoned-decimal format, each byte of storage is divided into two portions: a 4-bit zone portion and a 4-bit digit portion. The zoned-decimal format looks like this:
Figure 87. Zoned-Decimal Format
The zone portion of the low-order byte indicates the sign (positive or negative) of the decimal number. The standard signs are used: hexadecimal F for positive numbers and hexadecimal D for negative numbers. In zoned-decimal format, each digit in a decimal number includes a zone portion; however, only the low-order zone portion serves as the sign.Figure 88 shows what the number 21544 looks like in zoned-decimal format.
You must consider the change in field length when coding the end position in positions 40 through 43 of the Output specifications and the field is to be output in packed format. To find the length of the field after it has been packed, use the following formula:
You can specify an alternative sign format for zoned-decimal format. In the alternative sign format, the numeric field is immediately preceded or followed by a + or - sign. A plus sign is a hexadecimal 4E, and a minus sign is a hexadecimal 60.
When an alternative sign format is specified, the field length (specified on the input specification) must include an additional position for the sign. For example, if a field is 5 digits long and the alternative sign format is specified, a field length of 6 positions must be specified.
[ Top of Page | Previous Page |Next Page |Table of Contents |Index ]
- Zoned-Decimal
- Zoned-Based policy FW
- Decimal
- Decimal
- Decimal
- Decimal
- decimal
- mm_init分析(Zoned Buddy Allocator)
- decimal 四舍五入
- decimal system
- decimal类型
- python decimal
- mysql decimal
- DECIMAL NUMERIC
- 数据库 decimal
- decimal.Round
- 格式化Decimal
- 加减乘除Decimal
- google站内搜索代码
- 流知识的学习资料(-)
- VirtualBox中有4中网络连接方式
- python删除只读文件
- [软件工程]敏捷过程模型的特性研讨——源自newsmth上的讨论
- Zoned-Decimal
- git pro
- ubuntu系统VNC服务器安装配置
- 使用javascript的substr实现文字跑马灯
- 数据库数据生成word文档的方法
- 测试并行程序
- python list排序
- What does sp_reset_connection do
- oracle拼音排序