I have my request coming from sql server. This request is mapped to edi 820 schema in a mapping. And the edi message is sent to the trading partner.
I want my edi message to be generated in the format below:
ISA…..
GS……
ST*820*0001~
BPR…….
TRN……
N1……
N1*PE*…..
ENT…..
RMR…..
DTM…..
SE*9*0001~
ST*820*0002~
BPR…….
TRN……
N1……
N1*PE*…..
ENT…..
RMR…..
DTM…..
SE*9*0002~
ST*820*0003~
BPR…….
TRN……
N1……
N1*PE*…..
ENT…..
RMR…..
DTM…..
SE*9*0003~
GE…..
IEA*1*…..
But the message which is getting generated after the edi send pipeline is as below:
ISA……
GS…..
ST*820*0003~
BPR…..
BPR…..
BPR……
BPR……
TRN…..
TRN…..
TRN…..
TRN…..
N1*PR*…..
N1*PE*…..
N1*PR*…..
N1*PE*…..
N1*PE*…..
N1*PR*…..
N1*PE*…..
ENT*1~
RMR…..
DTM…..
RMR…..
DTM…..
RMR…..
DTM…..
RMR…..
DTM…..
SE*27*0003~
GE*1*3~
IEA*1*000000007~
As you can see, I want the output with different segments for each record in the request. But I am having the output generated as all the records put in the same ST and SE segment.
Please let me know if you want more details. Thanks in advance.