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 Not under consideration
Workspace COBOL Compilers
Categories z/OS
Created by Guest
Created on Sep 19, 2022

Cobol JSON PARSE - Keep unparsed JSON Structures/Fields

It should be possible to store everything that is attached under a JSON object that you specify in an Xer field.

For example, if I get a list of orders that I then have to pass on to subprograms, I would like to be able to parse {"topic": "xy", "orders": [{...}, {...}, {...}]], but the individual order JSONs as a string in an Xer field. Then the subprogram could parse this job JSON itself. You would then have to tell the JSON parse command that you do not want to parse the object orders.


We have use cases in which we do not want to parse the entire JSON in one go. In one instance, we get a list of tasks from an external API and depending on a field in the JSON, the tasks should be processed by different Cobol programs. Right now we have to specify all possible models for the tasks-object in order to not loose information when parsing the JSON.

Idea priority Medium
  • Admin
    Basil Kanneth
    Reply
    |
    Sep 29, 2022

    Greetings R+V Versicherung!

    Thank you for submitting an IDEA to COBOL for “COBOL JSON PARSE - Keep unparsed JSON Structures/Fields”. We understand your requirement, but because we have many other requirements for work on JSON PARSE, we suggest that you might be better off if you change the code on your side so that you do not have to wait (possibly) years for a change from IBM COBOL compiler/run time development. We have 2 possible solutions that you could use right away:

    1) Use JSON PARSE to get all of the data out of the JSON tests and into COBOL data items, and then use the data in the COBOL data items to make decisions, to pass to sub programs, etc. This solution means only 1 JSON PARSE, and using COBOL data in COBOL programs is much more natural than trying to pass JSON around and use JSON texts as a sort of ‘data store’.

    2) Use JSON PARSE to get some of the data out of the JSON tests and into COBOL data items, and then use the data in the COBOL data items to make decisions, then pass the entire JSON text to sub programs, etc. where they can use JSON PARSE again to get the details that they need. This solution means more than 1 JSON PARSE (as your suggested solution proposes), but does allow you to use JSON as the ‘data store’ if that is desirable.

    Please consider using one of the above approaches. Since there are alternative methods, we will be rejecting this Idea for now, but may consider it in the future.