![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
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 |
| extract column based on name | t27 | UNIX for Dummies Questions & Answers | 3 | 08-29-2007 01:04 PM |
| Select Record based on First Column | mgirinath | Shell Programming and Scripting | 8 | 07-16-2007 01:38 AM |
| column based search | user_007 | Shell Programming and Scripting | 8 | 07-01-2007 05:52 AM |
| Select records based on search criteria on first column | shashi_kiran_v | UNIX for Dummies Questions & Answers | 2 | 12-02-2005 01:49 PM |
| filter out certain column from a file | CamTu | Shell Programming and Scripting | 4 | 04-04-2005 06:24 PM |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
filter based on column value
I have a file with colon separated values.. the sample is attached below.
No of fields in each record/line is dependent on the value of field53. What I need to do is to design a special filter based on specific requirement of some match of values in particular column or combination of columns. I give an example.. my query may demand me to extarct all the lines that match the criterion field7=2230982599 AND field8=1232600248 I want the field no and the matching pattern to be variable... Hope I have clearly stated the problem. pART OF THE FILE LOOKS LIKE PACE | PCMD | 21.0 | 040507 | 18 | 3;10115950;611261;106440;3;8d2d9522;2230982599;1232600248;0;65;2;1;43;65;2;1;43; 1641;65;7;0;23811450;2;2;2;2;2;1;0;3;3;994;518;7;0;2;2;1;1;0;140;0;0;0;4;3;0;0;0 ;0;0;0;2;25;27; 3;10115951;612309;1100;1;8d31de39;2230983737;1232602026;0;33;2;1;34;33;2;1;34;0; 0;0;0;982014290;2;2;2;0;2;1;0;3;3;995;823;7;0;2;0;1;2;0;56;0;0;0;0;0;0;0;0;0;0;0 ;1;25; 3;10115952;612347;0;59;0;2233498694;0;2233498694;0;0;0;0;0;0;0;0;1885;230;7;0;0; 0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;1;8;0;0;0;0;0;0;0;0;0;0;0;0;4802828128;0; 3;10115953;611938;40797;3;44f2a266;2234358432;1075033834;0;12;2;2;2;12;2;2;2;617 ;69;7;1;02234204762;2;2;1;1;1;1;0;3;3;993;894;7;0;2;2;1;1;0;84;0;0;0;3;3;0;0;0;0 ;0;0;2;25;27; ................ |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|