# Validate Large EDI File

**URL:** <https://techcommunity.softwareag.com/t/validate-large-edi-file/108743>\
**Category:** Forum\
**Tags:** EDI\
**Created:** [January 27, 2005, 2:26am UTC](https://techcommunity.softwareag.com/t/validate-large-edi-file/108743 "2005-01-27T02:26:50Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![david.chen.43290](https://avatars.discourse-cdn.com/v4/letter/d/ea5d25/32.png) [@david.chen.43290](https://techcommunity.softwareag.com/u/david.chen.43290)\
**Post date:** [January 27, 2005, 2:26am UTC](https://techcommunity.softwareag.com/t/validate-large-edi-file/108743/1 "2005-01-27T02:26:50Z")

</div>

There is a EDI file sitting on the file system for validation. I would like to use wm.b2b.edi:envelopeProcess first. If I load file into string (getFile as bytes and convert to String) and call wm.b2b.edi:envelopeProcess, it is fine. But I cannot get stream version code to work (getFile as stream then envelopeProcess), it give me some error: Unrecognized EDI data (not ANSI X12 nor UN/EDIFACT).

Any suggestions? I am expecting large data set so string might not be enough (how big is it anyway?).

Thanks!

---

<div class="post-metadata">

**Author:** ![Chris\_L](https://avatars.discourse-cdn.com/v4/letter/c/ba9def/32.png) [@Chris\_L](https://techcommunity.softwareag.com/u/Chris_L)\
**Post date:** [January 27, 2005, 8:21am UTC](https://techcommunity.softwareag.com/t/validate-large-edi-file/108743/2 "2005-01-27T08:21:55Z")

</div>

try this  
wm.tn.doc:getContentPartData  
wm.b2b.edi.util.streamToString  
wm.b2b.edi.envelopeProcess

hth

---

<div class="post-metadata">

**Author:** ![david.chen.43290](https://avatars.discourse-cdn.com/v4/letter/d/ea5d25/32.png) [@david.chen.43290](https://techcommunity.softwareag.com/u/david.chen.43290)\
**Post date:** [January 27, 2005, 7:49pm UTC](https://techcommunity.softwareag.com/t/validate-large-edi-file/108743/3 "2005-01-27T19:49:10Z")

</div>

Thanks for the info. In my case, I have a large EDI file (say 100 MB), I am not sure about the streamToString can handle this. What do you think?

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/techcommunity/original/3X/c/d/cd19967bb605d28a72d77eb83a1cae22f3df2eb8.svg) [@system](https://techcommunity.softwareag.com/u/system)\
**Post date:** [April 2, 2021, 3:05pm UTC](https://techcommunity.softwareag.com/t/validate-large-edi-file/108743/4 "2021-04-02T15:05:21Z")

</div>

Closed on April 2, 2021, 3:05pm UTC


