![]() |
|
|
google unix.com
|
|||||||
| Forums | Casino | Register | Forum Rules | Links | Albums | FAQ | Members List | 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 |
| shell script to find and replace string in multiple files | pharos467 | Shell Programming and Scripting | 11 | 01-15-2009 10:40 AM |
| perl-like split function for bash? | eur0dad | Shell Programming and Scripting | 5 | 09-05-2008 06:23 PM |
| [KSH] Split string into array | piooooter | Shell Programming and Scripting | 3 | 09-01-2007 12:22 PM |
| split string help | senthilk615 | Shell Programming and Scripting | 4 | 03-27-2006 06:43 PM |
| split a string | gazingdown | Shell Programming and Scripting | 3 | 02-09-2006 04:34 AM |
![]() |
|
|
Submit Tools | LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|||
|
Hi all,
I have a file of around 300 lines in which string "SERVER" occurs around 32 times. for eg. Quote:
I need to split files like, for eg Quote:
awk '/SERVER/{n++}{print > f n}' f=/vikas/list /vikas/final But the problem is that it makes maximum of 10 files, but I need more than 30. I have tried using nawk, but didnt worked. I am using bash scripting on Sun OS. Any other way of splitting this data ??? Pls help !!! Thanks in adv. Regards, Vikas |
| Sponsored Links |
|
|||
|
Quote:
this cmd is making as many blank files as the string SERVER is there in the final file. pls help |
|
|||
|
Quote:
Thanks a ton friend. Its running on my Linux machine smoothly. Now I have to check it on Solaris machine, will do that tomorrow. Thanks again. |
|||
| Google The UNIX and Linux Forums |
![]() |
| Bookmarks |
| Tags |
| linux, linux commands |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|