1

I have cluster of 10 folders, each with 1000 program files. I need to search these text files for a string. All files must start with $O123456.MIN% (123456 bearing random file names). I know how to find if the string exists, but how do I identify if the string does not exist?

user1987121
  • 11
  • 1
  • 3

1 Answers1

1

Try this regex:

(?!(\$O[^\s]+\.MIN%)).*

It matches every string except of the form a $ followed by a O followed by 1 or more characters except whitespace followed by a . followed by MIN%

Naveed S
  • 5,106
  • 4
  • 34
  • 52
  • This is close, but it returns all rows in the file (1000+). And if ran againsts 1000 files, it seems to hang. The string I want to identify if it is NOT there, is always the first line. – user1987121 Jan 17 '13 at 13:32