03-21-2014
Amazing, it worked sir!
Thank you very much brave man
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi all,
I appreciate the enormous amount of knowledge that flows in this forum.
I am an average UNIX user. I have many files with lines like the below. I have separated each line with space for ease of reading. I need to replace the first occurance of "/00" with null on those lines that have... (6 Replies)
Discussion started by: Nanu_Manju
6 Replies
2. Shell Programming and Scripting
Hi ,
I need some help on perl/sed conditional replacement
The situation is like below .
I have a file contents like below .
AAA|BBB|CCC|DDD
AAA|BCF|CCC|HHH
AAA|BVF|JJJ|KKK
Here in the above file . I know my second column value (taking "|" as my delimited )
Basically I have to... (3 Replies)
Discussion started by: robin.r888
3 Replies
3. Shell Programming and Scripting
Given this row:
|lastname1|middlename1|firstname1|lastname2|middlename2|firstname2
produce this result:
|lastname|middlename|firstname
where the resultant names are based on the presence of the #2 names above. I.e., if a #2 name is passed (usually will be null,) use that - otherwise... (8 Replies)
Discussion started by: tiggyboo
8 Replies
4. Shell Programming and Scripting
i have few lines in a file... i am reading them in a while loop so a particular line is held is $line1.. consider a modified line is held in $line2.... i want to replace $line1 with $line2 in the same file... how to do it..?
i have come up till the below code
sed "s/$line1/$line2/g" tmpfile.sql... (5 Replies)
Discussion started by: vivek d r
5 Replies
5. Shell Programming and Scripting
I need to read the contents of a file. Then I need to grep for a keyword and replace part of the grepped line based on the condition of previous and present line.
Example input file:
V {
port1 = P;
port2 = 0;
shift_port = P0; /* if next shift_port is P0 I need... (9 Replies)
Discussion started by: naveen@
9 Replies
6. Shell Programming and Scripting
Hi How Are you?
I am doing fine!
I need to go now?
I will see you tomorrow!
Basically I need to replace the entire line containing "doing" with a blank line:
I need to the following output:
Hi How Are you?
I need to go now?
I will see you tomorrow!
Thanks in advance.... (1 Reply)
Discussion started by: sags007_99
1 Replies
7. Shell Programming and Scripting
my requirement is,
consider a file output
cat output
blah sdjfhjkd jsdfhjksdh
sdfs 23423 sdfsdf sdf"sdfsdf"sdfsdf"""""dsf
hellow there
this doesnt look good
et cetc etc
etcetera
i want to replace a line of line number 4 ("this doesnt look good") with some other line
... (3 Replies)
Discussion started by: vivek d r
3 Replies
8. Shell Programming and Scripting
All, I appreciate any help you can offer here as this is well beyond my grasp of awk/sed...
I have an input file similar to:
&LOG
&LOG Part: "@DB/TC10000021855/--F"
&LOG
&LOG
&LOG Part: "@DB/TC10000021852/--F"
&LOG Cloning_Action: RETAIN
&LOG Part: "@DB/TCCP000010713/--A"
&LOG
&LOG... (5 Replies)
Discussion started by: KarmaPoliceT2
5 Replies
9. Shell Programming and Scripting
Sed command to replace a line in a file using line number from the output of a pipe.
Is it possible to replace a whole line piped from someother command into a file at paritcular line...
here is some basic execution flow..
the line number is 412
lineNo=412
Now i have a line... (1 Reply)
Discussion started by: vivek d r
1 Replies
10. Shell Programming and Scripting
Hi all,
Let's say I have a script calling for the two variables PA_VALUE and PB_VALUE.
for pa in PA_VALUE
blah blah
do
for pb in PB_VALUE
blah blah
do
I have a text file with two columns of values for PA and PB.
14.5 16.7
7.8 9.5
5.6 3.6
etc etc
I would like to read this... (7 Replies)
Discussion started by: crimsonengineer
7 Replies
LEARN ABOUT DEBIAN
cancelmsg
CANCELMSG(1) Double Precision, Inc. CANCELMSG(1)
NAME
cancelmsg - Cancel an E-mail message
SYNOPSIS
cancelmsg {msgid} ["reason"]
DESCRIPTION
cancelmsg removes a message from the mail queue. There will be no more attempts to deliver this message, and a standard delivery failure
notice is sent to the return address listed on the message. You can only cancel your own messages. The superuser can cancel any message. An
attempt to cancel a message will fail if the message has already been sent (of course), or if a delivery attempt is currently in progress.
Because a delivery attempt is usually started as soon as an E-mail message is added to the mail queue, a cancellation attempt is only
effective if the message cannot be immediately delivered for some reason, or if the system is very busy and is working on a mail backlog.
cancelmsg works by marking all pending recipients as undeliverable. A non-delivery report is then generated and sent in the normal fashion.
msgid is the message queue id that can be obtained from the mailq(1)[1], command. A reason is optional. The message does not disappear into
a black void. The message will be returned as undeliverable, citing reason. A generic error message will be used if reason is not
specified.
BUGS
A non-delivery report may not be sent immediately, but delayed until the message's turn comes up in the scheduling queue.
There is no immediate indication if the message cancellation worked. A subsequent non-delivery report is the only indication of a
successful cancel. If it doesn't come, it means the message wasn't cancelled in time.
A non-delivery report will not be sent for recipients whose delivery status notification does not include the FAIL notice.
SEE ALSO
mailq(1)[1], courier(8)[2].
AUTHOR
Sam Varshavchik
Author
NOTES
1.
mailq(1)
[set $man.base.url.for.relative.links]/mailq.html
2.
courier(8)
[set $man.base.url.for.relative.links]/courier.html
Courier Mail Server 08/30/2011 CANCELMSG(1)