Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


how to use grep command to list find the records of a file
containg 10 different strings

Answers were Sorted based on User's Feedback



how to use grep command to list find the records of a file containg 10 different strings..

Answer / raghu

egrep "word1|word2" filename

Is This Answer Correct ?    27 Yes 2 No

how to use grep command to list find the records of a file containg 10 different strings..

Answer / siva

try this command

egrep "string1|string2|string3" <filename.extn>

Is This Answer Correct ?    12 Yes 2 No

how to use grep command to list find the records of a file containg 10 different strings..

Answer / raja

egrep "string1|string2" *.*

Is This Answer Correct ?    0 Yes 1 No

how to use grep command to list find the records of a file containg 10 different strings..

Answer / supriya

grep 'word1|word2' <filename>

Is This Answer Correct ?    1 Yes 5 No

how to use grep command to list find the records of a file containg 10 different strings..

Answer / umakanta

grep -w 'word1|word2' filename

Is This Answer Correct ?    8 Yes 14 No

Post New Answer

More Unix General Interview Questions

Suppose you have a scheduling chain where the process 1 is a predecessor of the process 2 and both of them are scheduled every Monday at 8.00pm. Will I find execution log of process 1 every Tuesday morning? And what about the other one? Why?

1 Answers   Accenture, IBM,


Is unix a coding language?

0 Answers  


Difference between the fork() and vfork() system call?

0 Answers  


How do I search for a grep file in unix?

0 Answers  


What is the core of unix operating system?

0 Answers  


Pipes support half duplex communication. But if we want full-duplex communications we should use two pipes between two processes. Is such situation can leads to deadlock? Write two scenarios that could leads to deadlock in such situations?

1 Answers   Vector India,


How to display the contents of a file?

0 Answers  


What is regular file in unix?

0 Answers  


In what way the Fault Handlers and the Interrupt handlers are different?

0 Answers  


What is unix and its features?

0 Answers  


What is .sh file in unix?

0 Answers  


How to log out in unix?

0 Answers  


Categories