A message sent to adapter "FILE" on send port "sp_856_EDI_Out_FILE"
with URI "e:\Messages\MyApp\Process\856EDI_Temp\%SourceFileName%" is suspended.
Error details: Unable to read the stream produced by the pipeline.
Details: Error: 1 (Field level error)
Position in TS: 9
Data Element ID: N401
Position in Segment: 1
6: Leading or trailing space found
Solution 1 – Fix the bad data
The N401 refers to the first element of the N4 segment, which is the city of the city, state, address.
In our case, the client sent us this in the EDI 850 message.
They should have trimmed the spaces after the city name of “CLOVIS”. Oddly enough, the error did not occur on the 850, but on the 856. So we stored the data in our database with the trailing blanks. We extract data to an XML file and saved to disk, so I was able to edit the XML and resubmit it. If you can do this or not depends on how you have your set up your send/receive port structure (or your orchestration flow).
Solution 2 – Turn off EDI validation
Validation can be changed as follows:
1) From BizTalk Admin console, expand the “Parties”
2) Find the Profile, then the Agreement for the specific party. Open the agreement.
3) Click on the top tab that indicates message sent to that party.
4) Click on the left option called “Validation” and you will see something like the screen below.