Jalcock501 has asked for the wisdom of the Perl Monks concerning the following question:
Hello fellow Monks
I come before you today with a strange question!
Here is the situation: In a file, I am comparing, it holds a record known as a G record (it begins with G) G3301R7435459:LNI10708. This record is made up of snippets from other E records:Sometimes multiple parts of E records or sometimes just one part. In the example given, the G record is made up of the 6th pipe delimitation on the first line and the 7th on the second, with a colon inbetween.E99POLCOM|3||CAP01|66|3301R7435459||||| E99INSFAC2|MSRA01_1||||||"LNI10708"|
Here is the question, the E segment varies in size to as much as 256bits, now how can I check the G record reflects the E segments correctly when I don't know what size they are? Is there a way to do something like this:
Please help... if this doesn't make sense or if you think you might need more information just let me know(SUDO) load pipe delimited into hash with first record as key: look at E99POLCOM[6] look at E99INSFAC2[7] if G eq "E99POLCOM[6]:E99INSFAC2[7]"{PASS;}
Thanks Jim
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Substrings of unusual size!
by RichardK (Parson) on Oct 09, 2013 at 15:16 UTC | |
Re: Substrings of unusual size!
by Anonymous Monk on Oct 09, 2013 at 15:26 UTC | |
Re: Substrings of unusual size!
by keszler (Priest) on Oct 09, 2013 at 15:18 UTC | |
Re: Substrings of unusual size!
by ww (Archbishop) on Oct 10, 2013 at 01:19 UTC | |
Re: Substrings of unusual size!
by boftx (Deacon) on Oct 09, 2013 at 22:54 UTC | |
Re: Substrings of unusual size! (variable length substrings)
by Anonymous Monk on Oct 10, 2013 at 00:08 UTC |
Back to
Seekers of Perl Wisdom