cancel
Showing results for 
Search instead for 
Did you mean: 

Mapping Error in SXMB_MONI

Former Member
0 Kudos

Hi,

I am facing a mapping error in SXMB_MONI. When I test Message Mapping and Interface Mapping independently, the test executes successfully, displaying the expected output. However when I execute the scenario as a whole, I get an error in SXMB_MONI saying "Runtime Exception: Different length of queues in SortByKey"

Please help me regarding the same.

Thanks and Regards,

Tejal

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Tejal,

This error is caused due to improper input to "sortbyKey" function.

The inputs to this function should have equal number of elements in them.

Just make sure that your input has the same.

Regards,

P.Venkat

Former Member
0 Kudos

Thank You Venkat for your input,

However I fail to understand why this error occurs only during execution of the entire scenario and not when I test Message Mapping. If the input to sortbyKey was improper, the Mapping etst should not have been successful...

One more thing I noticed, the Mesaage Mapping is being called twice during the execution of the scenario... and there is no difference in the payload in both the instances of "Request Message Mapping".

Former Member
0 Kudos

Hi,

In the test tab you might have given some other input.

One way is to copy the payload from SXMB_MONI and paste it in the test tab and test.

How is ur input triggered? you might have given the input file twice.

Regards,

P.Venkat

Answers (1)

Answers (1)

Shabarish_Nair
Active Contributor
0 Kudos

Ref. to the help doc statement.

<i>sortByKey -

Like sort, but with two inbound parameters to sort (key/value) pairs. The sort process can be compared to that of a table with two columns.

Using the first parameter, you pass key values from the first column, which are used to sort the table. If you have classified the key values as numeric in the function properties, they must not be equal to the constant ResultList.SUPPRESS. See also: The ResultList Object

Using the second parameter, you pass the values from the second column of the table.</i>

<i><b>If there is a discrepancy between the number of keys and values, the mapping runtime triggers an exception. The function returns a queue with the values sorted according to the keys.</b></i>

http://help.sap.com/saphelp_nw04/helpdata/en/43/c4cdfc334824478090739c04c4a249/content.htm