Skip to Main Content
IBM Power Ideas Portal


This portal is to open public enhancement requests against IBM Power Systems products, including IBM i. 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 IBM i
Categories Languages - RPG
Created by Guest
Created on May 22, 2022

%Split should allow array index

Currently %Split returns an array, but it would be nice if it would allow a single index of the array to be returned directly by coding for example mystring = %Split(string: ':')(1); This avoids using a work array.

Idea priority High
  • Guest
    Reply
    |
    Jun 1, 2022

    Regarding the third issue where you want to split on a string rather than a list of characters, please open a separate Idea. As a work-around, you could use %SCANRPL to replace the separator-value in the source string with a single character such as x'00' or some other character that is guaranteed not to be in the source string.

    - IBM Power Systems Development

  • Guest
    Reply
    |
    Jun 1, 2022

    Some comments...

    1. Needing the first (or any other element) of the array by using a For-Each loop is not practical as you can't write an expression, or pass it as a parameter to another procedure. For example instead of DoSomething(%Split(myString: ',')(1)) one would need to write several lines of code.

    2. Fine.

    3. What you're referring to is something different. I want to split on the string specified as the second parameter for %Split, even if this parameter is more than one character, ie. the characters should not be considered as multiple different delimiters but as one single (multi-char) delimiter.

  • Guest
    Reply
    |
    May 31, 2022
    IBM does not intend to provide a solution to this request at this time, so it is being closed.

    This requirement has several separate requests:
    1. Allow an index for %SPLIT. To avoid using a work array, you could process the output of %SPLIT using a FOR-EACH loop.
    FOR-EACH item in %split(string);
    // process item
    leave; // we only want the first item
    ENDFOR;
    2. The error message RNF0625 is misleading when it says that the result of %SPLIT or %SUBARR is not an array. This aspect of the requirement is accepted, and will be tracked internally by IBM.
    3. Treat each separator separately. There is already an Idea related to this. Please consider voting for that Idea instead. https://ibm-power-systems.ideas.ibm.com/ideas/IBMI-I-3007 ("%split() should return an empty element where a separator character follows another separator character")

    - IBM Power Systems Development