10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi all, I have a report that looks like this:
-------------------------------------------------
-- AOC - XXXXXXX --
-------------------------------------------------
Thread Last Sequence Received Last Sequence Applied Difference
----------... (12 Replies)
Discussion started by: cougartrace
12 Replies
2. Shell Programming and Scripting
I have a file is created from standard output.
I have put a leading space to force the first line to collate low vis a vis the rest of the lines.
If I pass the entire file to the Linux sort, it ignores the leading space and the first line appears in somewhere in the list.
If I add lots of... (15 Replies)
Discussion started by: lsatenstein
15 Replies
3. Shell Programming and Scripting
Hello friends,
I have a file with duplicate lines. I could eliminate duplicate lines by running
sort <file> |uniq >uniq_file and it works fine BUT it changes the order of the entries as it we did "sort".
I need to remove duplicates and also need to keep the order/sequence of entries. I... (1 Reply)
Discussion started by: magnus29
1 Replies
4. Shell Programming and Scripting
HI I am executing faloowing commands.
mr batch_1 > my_temp.txt ;
mr batch_2 >>my_temp.txt;
mr batch_3 >> my_temp.txt;
mr batch_4 >> my_temp.txt;
and the out put file is as this
cat my_temp.txt
Machine Name Max Load Current Load Factor O/S Status... (3 Replies)
Discussion started by: ptappeta
3 Replies
5. Shell Programming and Scripting
Hi All,
I am trying write a simple command using AWK and SED to this but without any success.
Here is what I am using:
head -1 test1.txt>test2.txt|sed '1d;$d' test1.txt|awk '{print substr($0,0,(length($0)-2))}' >>test2.txt|tail -1 test1.txt>>test2.txt
Input:
Header
1234567
abcdefgh... (2 Replies)
Discussion started by: nvuradi
2 Replies
6. Shell Programming and Scripting
Currently I have the following to separate the numeric values. However the decimal point get separated.
ls -lrt *smp*.cmd | awk '{print $NF}' | sed 's/^.*\///' | sed 's/\(*\)/ & /g'
As an example on the files
n02-z30-dsr65-terr0.50-dc0.05-4x3smp.cmd... (8 Replies)
Discussion started by: kristinu
8 Replies
7. Shell Programming and Scripting
Hi,
I am having a file which is fix length and comma seperated. And I want to replace values for one column.
I am reading file line by line in variable $LINE and then replacing the string.
Problem is after changing value and writing new file temp5.txt, formating of original file is getting... (8 Replies)
Discussion started by: Mruda
8 Replies
8. UNIX for Dummies Questions & Answers
So, I have a file that has some duplicate lines. The file has a header line that I would like to keep at the top.
I could do this by extracting the header from the file, 'sort -u' the remaining lines, and recombine them. But they are quite big, so if there is a way to do it with a single... (1 Reply)
Discussion started by: Digby
1 Replies
9. AIX
I need help to split a filename 'a0crk_user:A0-B0123$#%test' into a0crk_user and A0-B0123 and print the output under 2 different columns namely
User and Status.
for eg. the output should like below:
User Status
---- ------
a0crk_user A0-B0123 (3 Replies)
Discussion started by: mbak
3 Replies
10. UNIX for Dummies Questions & Answers
I'm trying to see if there's a way to see column headings when I type the
ls -l command.
I know what some of the fields mean for example in the following listing:
total 136
drwxr-xr-x 2 root root 4096 Jun 5 15:16 bin
drwxr-xr-x 3 root root 4096 Jul 9 15:25 boot
drwxr-xr-x 9... (6 Replies)
Discussion started by: thoughts
6 Replies