|Just another Perl shrine|
Searching and Coutning using 2 files with multiple columnsby shart3 (Novice)
|on Sep 16, 2009 at 14:17 UTC||Need Help??|
shart3 has asked for the wisdom of the Perl Monks concerning the following question:
Good Morning Monks,
I have a problem that I could do rather easily in Excel, but my files are too large, and I can't seem to figure out a way for perl to do it, although I know it can.
I have two files Boundary.out and DB.out. Boundary.out look like this:
and DB.out looks like this:
for each row in DB.out I want to count the number of times that a row in Boundary.out occurs where column 0 in Boundary.out eq col1 in DB.out AND col1(Boundary) gt col2(DB) AND col2(Boundary)lt col3(DB). That value should be added to col7(DB).
Here is what I have so far:
Can anyone help????????????