10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
In the awk below I am trying to cp and paste each matching line in f2 to $3 in f1 if $2 of f1 is in the line in f2 somewhere. There will always be a match (usually more then 1) and my actual data is much larger (several hundreds of lines) in both f1 and f2. When the line in f2 is pasted to $3 in... (4 Replies)
Discussion started by: cmccabe
4 Replies
2. Shell Programming and Scripting
hi all,
i had the below script
x=`cat input.txt |wc -1`
awk 'NR>1 && NR<'$x' ' input.txt > output.txt
by using above script i am able to remove the head and tail part from the input file and able to append the output to the output.txt but if i run it for second time the output is... (2 Replies)
Discussion started by: hemanthsaikumar
2 Replies
3. Shell Programming and Scripting
Hi All,
Please help me in the below issue.I had a file called env.prop.In that i need to change service.url.If i select chocie 2.
it should come as https://dev2.ecif.info53.com:30102/soap/default
30102 port is not fixed .It varies when the file is updated.So i want to keep orginal port in... (3 Replies)
Discussion started by: bhas85
3 Replies
4. Shell Programming and Scripting
Dear All I have a big set of data which I would like to summerize to have a better sense of it
the problem is like this ...
I have more than 200 files each related to a person which includes different sentences with specific elements (files in a directory)
e.g. mark (one file in the directory)... (9 Replies)
Discussion started by: A-V
9 Replies
5. Shell Programming and Scripting
Hi All,
I have 100's of files in the following format. I need to grep or parse out some values from each of the files
{
“tree”: “((A:0.2{0},B:0.09{1}):0.7{2},C:0.5{3}){4};”,
“placements”:
, ], “n”: },
{“p”: ], “n”: }
],
“metadata”:
{“invocation”:
“pplacer -c... (1 Reply)
Discussion started by: Lucky Ali
1 Replies
6. Shell Programming and Scripting
Hi all - I''m in a little bit of jam - If you can please help
I have a file that has the following content ( please see below)
I need to read the file and then get this result in this format
------------- To put out in this format
name: sophis Total: 22328
name: tca ... (2 Replies)
Discussion started by: mnassiri
2 Replies
7. Shell Programming and Scripting
Hello, this is probably a simple request but I've been toying with it for a while.
I have a large list of devices and commands that were run with a script, now I have lines such as:
a-router-hostname-C#show ver
I want to print everything up to (and excluding) the # and everything after it... (3 Replies)
Discussion started by: ippy98
3 Replies
8. Shell Programming and Scripting
Hi i am using shell script which perform oracle database query and after that output is redirect to some temporary file.
the output of this file looks like
SQL*Plus: Release 10.2.0.2.0 - Production on Tue Aug 5 16:08:06 2008
Copyright (c) 1982, 2005, Oracle. All Rights Reserved.
... (6 Replies)
Discussion started by: esungoe
6 Replies
9. Shell Programming and Scripting
I am using awk command for greping an value from the file
the file contains ..
file
----------------------------
content-----------
--------
String main = "81507066666";
------------------------------
i am greping the above value using awk command
NumberToReplace=`cat "file" | grep... (1 Reply)
Discussion started by: vastare
1 Replies
10. Shell Programming and Scripting
i have a script that checks inside the file and find the start date and end date with time...........
#!/bin/ksh
cd /ednadtu3/u01/pipe/logs
TZ=`date +%Z`+24 ;b=`date +%Y-%m-%d`
echo $b
for i in DBMaint.log
do
echo "Start Time:" >> /ednadtu3/u01/pipe/naveed/Report.txt
cat $i | grep... (3 Replies)
Discussion started by: ali560045
3 Replies