Skip to Content

Typical Issue

Hi all,

Actually am facing a typical issue ,in the which the issue is related to the mapping .

when the OTYPE and STEXT fields of E1P1000 segment are equal then it should replicate the Job _title output field

For this i have written a code and it was working up to pre- production system but why it was failing in Production ???

Error :

Details:; Runtime exception when processing target-field mapping /ns0:/Record[270]/Job_Title; root message: Exception:[java.lang.ArrayIndexOutOfBoundsException: while trying to load from index 2 of an object array with length 2, loaded from the second parameter of the method] in class

Mapping :

helping me will be very appreciation



3.PNG (5.2 kB)
4.PNG (7.2 kB)
Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Oct 21, 2015 at 10:03 AM

    HI ,

    I am thinking below is the causes,

    1. Job_Title filed must be 1:1 occurence

    2.OTYPE field might have come other than value "C" and same time you had mapped root node of Job_Title field mapped 1 to 1

    so please check with root node of Job_Title node count and OTYPE  field match with value :C: count should be same


    Root node comes 10times, then OTYPE fields also matched with C" 10 times

    Add comment
    10|10000 characters needed characters exceeded

  • Oct 21, 2015 at 10:04 AM

    Hi Vijender,

    Can you please share a screenshot with queues when running the mapping using the input message from production? It seems that there is a different number of entries for OTYPE and STEXT, so you should consider using mapWithDefault before your UDF. Also, this can be handled using standard IF function without UDF at all.



    Add comment
    10|10000 characters needed characters exceeded

    • Hello vijendar



      OTYPE---->                                 ---------------------------------->Job_Title

                          Stext---------- Then

      If its not working try adding Remove context before equals for both the fields.

  • avatar image
    Former Member
    Nov 02, 2015 at 10:22 AM

    Hi Vijendar,

    As per my understanding, you have two fields i.e otype,stype. If otype vlaue is 'O' and Stype value is not empty (' ') you wanted to pass the value of stype to target. Else you wanted to add a ' ' value to target.

    This logic can be handled without a UDF. If otype -> Map with default-.> EQUALS "O" AND Stype-> EQUALS " "(constant " ")-> NOT then STYPE else Constant " ",

    Check the context of both the fields as well. Let us know if you face any issues.


    Add comment
    10|10000 characters needed characters exceeded