I have 2 xmls each containing multiple 270 requests. I have a map that maps the xml to 270 EDI and I have a solution that generates one 270 file per one xml file. The idea is to batch both these X12 270 files into one file. I can use a receive port again to pick up the generated 270s and create batch file. But I want to skip the extra step by promote the properties needed for batching from my orchestration and handle in the message box itself. I promoted the DestinationPartyName, BatchName and ToBeBatched properties. I have configured the party, agreement and batching. When I drop the xmls to generate 2 transaction sets in one file, I receive the below error
Inner exception: The batch element is being suspended as it either failed schema validation or context properties are not matching batch definition. The error is : Stopping after the first error !!
Error: 1 (Field level error)
SegmentID: ST
Position in TS: 1
Data Element ID: ST02_TransactionSetControlNumber
Position in Segment: 2
Data Value: 1
4: Data element too short
I tried generating the files separately without batching, the files get generated. This error occurs only when i include batching. How can I fix this?