IBM Sterling Transformation Extender

Sterling Transformation Extender

Come for answers, stay for best practices. All we're missing is you.


#Sterling
 View Only
  • 1.  Zero filled numeric field mapping as NONE when using NUMBERTOTEXT in output

    Posted 3 days ago

    v11.0.2 running on Windows 11.

    Input filed is zero filled.  Output field is text.  The zeros don't map and the field ends up empty which results in invalid X12.

    Input filed ==> 000000000

    Output ==> ADX**K2 (element 2 is mandatory and I would expect zeros).

    Thanks.



    ------------------------------
    Steve Arbo
    ------------------------------


  • 2.  RE: Zero filled numeric field mapping as NONE when using NUMBERTOTEXT in output

    Posted 11 hours ago
    Edited by Rich McFate 11 hours ago

    Steve -- when an input field contains nothing but pad characters, as appears to be the case here, it evaluates to NONE.

    So what happens next depends upon the context of the output.  In the case of an ADX segment I'm looking at (5010), it comprises two required elements followed by a Ref# Composite, which is in effect two optional elements.

    So if you're mapping your NUMBERTOTEXT(<input field>) into ADX01 and "K2" into ADX02, I would expect to see exactly what you're seeing.  Mapping NONE into a required field will build the empty field.  Mapping NUMBERTOTEXT(NONE) will still be an empty field.

    If you need to see ' 000000000' in your output, I suggest:

    Either(NUMBERTOTEXT(<inputField>),"000000000")

    This is not in the spirit of the X12 standards, which are designed to eliminate all unnecessary characters, but I appreciate some ICs require it.

    Cheers,

    Rich



    ------------------------------
    Rich McFate
    ------------------------------