Skip Menu |

This queue is for tickets about the X12 CPAN distribution.

Report information
The Basics
Id: 3716
Status: resolved
Priority: 0/
Queue: X12

People
Owner: Nobody in particular
Requestors: rstevens [...] clerk.com
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: (no value)
Fixed in: (no value)



Subject: multiple ISA Segments
Prasad, It looks like the vector stuff is saving some memory and allowing for larger files. However, I have found another possible problem. There is a possibility that an X12 data file may contain multiple ISA segments. The X12 module only pulls delimiters out of the first segment of the file and uses those delimiters to parse the data elements out of ALL of the remaining segments of the file. Each ISA segment has its own set of delimiters that should be used. If multiple ISA envelopes are encountered in an X12 data file, the segments in that ISA envelope should be parsed according to the delimiters in the ISA segment for that envelope. I deal specifically with X12 837 transactions. I had some very rough ideas to accomplish this, but i think your knowledge of Perl is better than mine and you could probably do it better. My idea would be to split it up into seperate files for each ISA envelope. Thanks, Randall
[guest - Wed Sep 3 20:41:11 2003]: You can get around this "multiple ISA envelope" problem be doing the following: 1) break the incoming X12 data file into individual "subfiles". each subfile will contain a single ISA envelope worth of data 2) declare and array of 'parser' objects in your Perl code 3) loop through all of the subfiles created in 1) and assign an array parser object to each one. evhorig@yahoo.com Show quoted text
> Prasad, > > It looks like the vector stuff is saving some memory and > allowing for larger files. However, I have found another > possible problem. There is a possibility that an > X12 data file may contain multiple ISA segments. The X12 module > only pulls delimiters out of the first segment of the file > and uses those delimiters to parse the data elements out of > ALL of the remaining segments of the file. Each ISA segment has > its own set of delimiters that should be used. > > If multiple ISA envelopes are encountered in an X12 data file, > the segments in that ISA envelope should be parsed according to > the delimiters in the ISA segment for that envelope. > > I deal specifically with X12 837 transactions. I had some very > rough ideas to accomplish this, but i think your knowledge of Perl > is better than mine and you could probably do it better. My idea > would be to split it up into seperate files for each ISA envelope. > > Thanks, > > Randall