![]() |
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Search for a word | on9west | Shell Programming and Scripting | 2 | 04-23-2008 04:15 AM |
| Word search in awk | videsh77 | Shell Programming and Scripting | 8 | 03-08-2007 11:40 PM |
| Search about word | abu_hassan | SUN Solaris | 3 | 02-19-2007 01:17 PM |
| search for certain word in a files from directory | legato | UNIX for Dummies Questions & Answers | 1 | 10-31-2006 06:35 AM |
| Is there any way to open vi on line or word ? | umen | UNIX for Dummies Questions & Answers | 1 | 04-26-2006 11:25 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread |
Rating:
|
Display Modes |
|
|
|
||||
|
Hi guys,I m new one in awk scripting....i want to search a word with in a directory...in that directory haviing many files...if i give a work ,it should open the directory and open each file for to search that particular word....is it possible in awk...tell me guys its really urgent....
|
|
||||
|
Hi ,
Doubt on u r Q ..? 1.U want the only list of the files which are WORD contains ..?? or 2.U want search the WORD and process using the awk ..?? For 1st :Try this grep -l <word> <Dir_Path>/*.* for 2nd :Try this => will print the line awk '{ if ( $0 ~/<word>/ ) {print $0} }' <Dir_Path>/*.* Try this let me know its working for u or not happy learning .thanks Raj |
|
||||
|
Thank raj....
can we give the directory path inside the program...not in comman line....i m writing a program in a file...then i m executing that file...so can u tell me that how can we give the directory path inside the program...i tried a lot.... |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|