Sponsored Content
Top Forums Shell Programming and Scripting Where condition in grep or awk? Post 302770363 by yadavricky on Friday 15th of February 2013 11:05:49 AM
Old 02-15-2013
RedHat still not working

No its not working can you please check i am getting the blank value
 

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

grep command with AND condition

I want to do a grep with AND condition. I have three files. file1.txt ======== UNIX ...... WINDOWS ........ ORACLE file2.txt ======== UNIX ....... WINDOWS ...and many such files in a directory (6 Replies)
Discussion started by: prasperl
6 Replies

2. Homework & Coursework Questions

Grep line above X condition

1. The problem statement, all variables and given/known data: I have to grep a data file called datebook.txt. The last information in each line is a salary. I have to grep all the lines which precede those lines with 6 figure salaries. I can't SID it, or use Perl. It has to be grep (or egrep or... (3 Replies)
Discussion started by: DrSammyD
3 Replies

3. Shell Programming and Scripting

grep inside if condition - need help

hi i need help with below code. if ] then log "Exiting the script as ID= NULL" log "Please run script first." fi i am calling grep inside this but its not running any ideas why ?? input file is like this -- Msg 102, Level 20, State 1: Server... (4 Replies)
Discussion started by: dazdseg
4 Replies

4. Shell Programming and Scripting

use awk pick value from lines as condition for grep

Hi Folks! I have a file like this 000000006 dist:0.0 FILE ./MintRoute/MultiHopWMEWMA.nc LINE:305:1 NODE_KIND:131 nVARs:4 NUM_NODE:66 TBID:733 TEID:758 000000000 dist:0.0 FILE ./Route/MultiHopLEPSM.nc LINE:266:1 NODE_KIND:131 nVARs:4 NUM_NODE:66 TBID:601 TEID:626 000000001 ... (2 Replies)
Discussion started by: jackoverflow
2 Replies

5. Shell Programming and Scripting

grep in the if condition

Hi, In this code can able to match the pattern without case sensitive. Is that possible? if u knw plz help me... code: echo "Enter name to search" read n if ; echo "name found" else echo "Not Found" fi (8 Replies)
Discussion started by: boopal
8 Replies

6. Shell Programming and Scripting

grep not equal to condition

I have below files under dir_a and dir_b and i want to sort out number of dir_a and dir_b files seperately and if i do the grep it should retrun 2 files in dir_a and 1 file in dir_b. /dir_a/12345678 /dir_a/87654321 /dir_a/dir_b/12345687 But i am getting cat file|grep dir_a|wc -l 3... (6 Replies)
Discussion started by: prash358
6 Replies

7. UNIX for Dummies Questions & Answers

Grep certain lines with condition

file input aaaa,52C aaaa,50C bbbb,50C bbbb,58C aaaa,52C bbbb,50C aaaa,30C bbbb,58C cccc,60C i want to print uniq lines with its max value of column2 expected output aaaa,52C bbbb,58C cccc,60C tks (4 Replies)
Discussion started by: radius
4 Replies

8. UNIX for Dummies Questions & Answers

How to grep with certain condition?

hi all, i have an xml what i have to do is to search for the source id(s1) and if it matches with that in xml then extract the file mask from the name of the file i.e if the file name is idr_%YYYY%%MM%%DD%_%N%.idr then , i want the part after first % and before last % ie in this case ... (5 Replies)
Discussion started by: ramsavi
5 Replies

9. UNIX for Dummies Questions & Answers

Grep with condition

I have file input AAAA_XX_Start> rlong . 0W 130526-11:36:13 10.128.13.226 9.0j RBS_NODE_MODEL_N_1_50 stopfile=/tmp/13019 .. ================================================================================================================= MO ... (2 Replies)
Discussion started by: radius
2 Replies
rcsdiff(1)						      General Commands Manual							rcsdiff(1)

NAME
rcsdiff - compareRCS revisions SYNOPSIS
rev1] rev2] file ... DESCRIPTION
compares two revisions of each given RCS file and creates output very similar to (see diff(1)). A file name ending in is an RCS file name, otherwise it is a working file name. derives the working file name from the RCS file name and vice versa, as explained in rcsintro(5). Pairs consisting of both an RCS and a working file name can also be specified. recognizes the following options: Same as described in diff(1); Same as described in diff(1); Same as described in diff(1); Same as described in diff(1); Generate an edit script of the format used by RCS. Generate a diff with lines of context. The default is to present 3 lines of context. To change, specify n; for example, gives 10 lines of context. modifies the output format slightly from the normal diff(1) output. The ``context'' output begins with identification of the files involved and their creation dates, then each change is separated by a line with a dozen (asterisks). Lines removed from file1 are marked with (dashes); those added to file2 with (pluses). Lines that are changed from one file to the other are marked in both files with (exclamation marks). If both rev1 and rev2 are omitted, compares the latest revision on the trunk with the contents of the corresponding working file. This is useful for determining what was changed since the last check-in. If rev1 is given, but rev2 is omitted, compares revision rev1 of the RCS file with the contents of the corresponding working file. If both rev1 and rev2 are given, compares revisions rev1 and rev2 of the RCS file. Both rev1 and rev2 can be given numerically or symbolically. EXAMPLES
Compare the latest trunk revision of RCS file and the contents of working file Compare the revisions 1.1 and 1.2 in the RCS file AUTHOR
was developed by Walter F. Tichy. SEE ALSO
ci(1), co(1), diff(1), ident(1), rcs(1), rcsmerge(1), rlog(1), rcsfile(4), rcsintro(5). rcsdiff(1)
All times are GMT -4. The time now is 11:30 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy