cancel
Showing results for 
Search instead for 
Did you mean: 

OneToMany function doesn´t work in post exit mapping of Iflow

gadirov
Participant
0 Kudos

Dear CPI experts,

unfortunately, the oneToMany mapping expression doesn´t work in the same way or is buggy in post exit. The same expression that works within the standard iFlow doesn´t work in post exit extension iflow. The error message is:

"Too few values in first queue in function useOneAsMany. It must have the same number of contexts as second queue" using mapping in CPI". The reason why we have to use this function is because we have to rebuild duplicate segments that cannot be taken over automatically to post exit while designing the iflow. It is a manual step in regards of mapping and must be built from, e.g. segment E1BPSDTEXT[1] (see the index) must be rebuild in post exit where we use the oneToMany according to standard mapping in main iflow. Our scenario is the erp replication of sales orders to ERP within the SalesQuoteFollowUp Iflow.

Do you have any experience on this behalf or can you propose any alternative ways to oneToMany expression?

BR & many thanks
Rufat

asutoshmaharana2326
Active Participant

Dear Rifat,

Is it possible to share a display queue of UseOneAsMany function with some sample data. Generally the context change of input one and input two should be same while implementing UseOneAsMany.

Thanks,

Asutosh

Accepted Solutions (1)

Accepted Solutions (1)

0 Kudos

Hi Rufat,

first queue has 2 context and second context has 4 context, as per the rule both should be equal.

- avinash

gadirov
Participant
0 Kudos

Thank you very much, Avinash! Indeed, the TextContent and ID did have different contexts which I oversaw...not the behaviour is the same and it works without issues!

BR
Rufat

Answers (1)

Answers (1)

gadirov
Participant
0 Kudos

Hi @asutoshmaharana2326,

thank you for your support.

This is the error message I get, I am going to post some sample data.

Source Message Queues:

ITM_NUMBER (I replaced ID from example because formatted)

TextContent - 8 entries

During oneToMany mapping the line item 10 data gets lost: This is the main issue which leads to errors:

End result is: Position 10 is null or empty....why does this issue happen only within postExit? That´s the case for every post exit adaptation, because standard iflow oneToMany works as expected....

BR
Rufat