HI All,
I am new in Unix,
I am using SSH secure shell,i want to search file with some 'TEXT' or string
and that string is like 'PACKAGE',followed by '%PA%EVENTS%'('PA_PACKAGE %PA%EVENTS%')
this % i am assuming as in SQL*PLUS,means i a string PA can occur any where before EVENTS
and EVENTS can occur any where after PA,
I want to search those file which this REGEX matches.
Please suggest.!!!
views:
57answers:
3but there is a space btween PACKAGE and '%PA%EVENTS%..
Vineet
2010-10-04 14:58:10
Both are not working
Vineet
2010-10-04 15:19:49
"E*E" means two or more Es, your wan't "E.*E" meaning E + any number of any character + another E. See Beano's example.
Frayser
2010-10-05 15:13:43
+1
A:
I ma not sure exactly what you are hoping to match, but the following will print out the lines that contain the text "PACKAGE" followed but zero or more characters and then the text "EVENTS", from all the files in the current directory.
grep "PACKAGE.*EVENTS" *
Please give some more examples of what you want, so I can be more specific.
Beano
2010-10-04 16:45:17