![]() |
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Find number of columns in a file | rahul26 | UNIX for Dummies Questions & Answers | 13 | 05-08-2009 06:11 AM |
| awk / grep / Prints all columns except the first one | knijjar | Shell Programming and Scripting | 17 | 02-29-2008 05:14 AM |
| How to grep a number in a file name | ahjiefreak | Shell Programming and Scripting | 3 | 12-11-2007 04:56 AM |
| Grep a number from a line in ksh | rodluo | Shell Programming and Scripting | 3 | 12-09-2007 09:31 AM |
| Finding number ranges using grep | DKNUCKLES | Shell Programming and Scripting | 2 | 11-07-2007 02:30 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
using Grep for only a certain number of columns
I am given a file with a list of names for the first 20 characters. The 20 characters after is a list of names that somebody is supposed to team up with.
Now i'm trying to write a simple script that will read a name somebody inputs and then looks only in the first 20 characters. For example. (Due to the nature of BBS posting length of columns are not given, the first name is the desired target for searching, the second name is the person teamed up with the first. John Bow : Lucy Hemmings Bob Billy : Bibliotheque Frenchness Lucy Hemmings : John Bow if somebody inputs John, I would get both Lucy and John, and this is not what I want. Any ideas? I am considering piping grep -w with something else as it seems to at least cut out all the names which have no relevance. |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|