in reply to search match within flat text file
Hope that helps.... #don't do `cat ...` open( FH, "<flatfile.txt") or die "Can't open flatfile.txt:$!\n"; my @matches = grep /File Error/, <FH>; if ( $#matches > -1 ) { print "Got " . ($#matches + 1) . " matches\n"; }
|
|---|