Skip to Main Content
IBM Z Software


This portal is to open public enhancement requests against IBM Z Software products. To view all of your ideas submitted to IBM, create and manage groups of Ideas, or create an idea explicitly set to be either visible by all (public) or visible only to you and IBM (private), use the IBM Unified Ideas Portal (https://ideas.ibm.com).


Shape the future of IBM!

We invite you to shape the future of IBM, including product roadmaps, by submitting ideas that matter to you the most. Here's how it works:

Search existing ideas

Start by searching and reviewing ideas and requests to enhance a product or service. Take a look at ideas others have posted, and add a comment, vote, or subscribe to updates on them if they matter to you. If you can't find what you are looking for,

Post your ideas
  1. Post an idea.

  2. Get feedback from the IBM team and other customers to refine your idea.

  3. Follow the idea through the IBM Ideas process.


Specific links you will want to bookmark for future use

Welcome to the IBM Ideas Portal (https://www.ibm.com/ideas) - Use this site to find out additional information and details about the IBM Ideas process and statuses.

IBM Unified Ideas Portal (https://ideas.ibm.com) - Use this site to view all of your ideas, create new ideas for any IBM product, or search for ideas across all of IBM.

ideasibm@us.ibm.com - Use this email to suggest enhancements to the Ideas process or request help from IBM for submitting your Ideas.

Status Future consideration
Workspace COBOL Compilers
Categories z/OS
Created by Guest
Created on Jul 15, 2024

IBM Enterprise COBOL - Add support for BINARY-CHAR, BINARY-SHORT, BINARY-LONG, BINARY-DOUBLE as alternative to COMP-5

Hi,


The COMP-5 USAGE, (or TRUNC(BIN) compilation option), allows binary values ​​to be stored according to the entire storage capacity of the machine's internal representation.

However COMP-5 is a constructor implementation and have portability problems.

We want to implement USAGE that are constructor independent, and the ISO standard defines them: BINARY-CHAR, BINARY-SHORT, BINARY-LONG, BINARY-DOUBLE.


ISO USAGE COMP-5 USAGE Range of values

---------------------- ------------- -----------------------------------------------------------------

BINARY-CHAR SIGNED N/A -128 [-2**7] <= n < 128 [2**7]

BINARY-CHAR UNSIGNED N/A 0 <= n < 256 [2**8]

BINARY-SHORT SIGNED S9(4) COMP-5 -32768 [-2**15] <= n < 32768 [2**15]

BINARY-SHORT UNSIGNED 9(4) COMP-5 0 <= n < 65536 [2**16]

BINARY-LONG SIGNED S9(9) COMP-5 -2147483648 [-2**31] <= n < 2147483648 [2**31]

BINARY-LONG UNSIGNED 9(9) COMP-5 0 <= n < 4294967296 [2**32]

BINARY-DOUBLE SIGNED S9(18) COMP-5 -9223372036854775808 [-2**63] <= n < 9223372036854775808 [2**63]

BINARY-DOUBLE UNSIGNED 9(18) COMP-5 0 <= n < 18446744073709551616 [2**64]


To see if for these USAGE the PICTURE clause remains required.

If present it can define the number of equivalent decimal digits allowed to represent the value.

In the presence of a PICTURE, the SIGNED / UNSIGNED clause would not be required or should be consistent with the PICTURE.


Thanks.

Idea priority Medium
  • Admin
    Basil Kanneth
    Reply
    |
    Sep 24, 2024

    This request is being accepted. It will be updated once put into plan.

  • Guest
    Reply
    |
    Jul 31, 2024

    Hi,

    No, no application porting project, but "who knows"...

    It is more a position of principle which is to be as independent as possible from a specific implementation of a manufacturer. In the same way that we favor "binary" instead of "comp" or "comp-4", "packed-decimal" instead of "comp-3", we would like to use declarations provided a priori in the COBOL standard for the "comp-5" declarations.

    In the same way that we favor "binary" instead of "comp" or "comp-4", "packed-decimal" instead of "comp-3", we would like to use declarations (provided a priori in the COBOL standard) for "comp-5" declarations.

    There will remain the case of "comp-1" and "comp-2", and "display-1" for which I do not know if there is a correspondence in a standard declaration not linked to a constructor implementation, but the use cases of these formats remain the exception.

    Thanks.

  • Admin
    Basil Kanneth
    Reply
    |
    Jul 30, 2024

    Hi Denis, in regards to portability, may we know if you are looking to port an application onto our COBOL product? and if so, how are things defined right now?