Dec 6, 2004 #1 BryanY MIS Aug 18, 2001 54 US Ok, basically I want to search a text file to see if one word, or another word, or a third word is present. I tried grep -F 'first second third' file but it doesn't seem to work. Any suggestions? (i used /usr/xpg4/bin/grep [Solaris] )
Ok, basically I want to search a text file to see if one word, or another word, or a third word is present. I tried grep -F 'first second third' file but it doesn't seem to work. Any suggestions? (i used /usr/xpg4/bin/grep [Solaris] )
Dec 6, 2004 #2 vgersh99 Programmer Jul 27, 2000 2,146 US egrep '(first|second|third)' file vlad +----------------------------+ | #include<disclaimer.h> | +----------------------------+ Upvote 0 Downvote
egrep '(first|second|third)' file vlad +----------------------------+ | #include<disclaimer.h> | +----------------------------+
Dec 6, 2004 #3 vgersh99 Programmer Jul 27, 2000 2,146 US or: /usr/xpg4/bin/grep -E '(first|second|third)' file vlad +----------------------------+ | #include<disclaimer.h> | +----------------------------+ Upvote 0 Downvote
or: /usr/xpg4/bin/grep -E '(first|second|third)' file vlad +----------------------------+ | #include<disclaimer.h> | +----------------------------+
Dec 6, 2004 #4 ericbrunson Technical User Jan 9, 2004 2,092 US or "grep -e first -e second -e third file Upvote 0 Downvote
Dec 6, 2004 #5 fredericofonseca IS-IT--Management Jun 2, 2003 3,324 PT But really nothings is better than man grep Regards Frederico Fonseca SysSoft Integrated Ltd http://www.syssoft-int.com Upvote 0 Downvote
But really nothings is better than man grep Regards Frederico Fonseca SysSoft Integrated Ltd http://www.syssoft-int.com