10 More Discussions You Might Find Interesting
1. Solaris
Hi,
I need to compare the /etc/passwd files from 2 servers, and extract the users that are similar in these two files. I sorted the 2 files based on the user IDs (UID) (3rd column). I first sorted the files using the username (1st column), however when I use comm to compare the files there is no... (1 Reply)
Discussion started by: anaigini45
1 Replies
2. Shell Programming and Scripting
Hello all,
I have a large csv file where there are four types of rows I need to merge into one row per person, where there is a column for each possible code / type of row, even if that code/row isn't there for that person.
In the csv, a person may be listed from one to four times... (9 Replies)
Discussion started by: RalphNY
9 Replies
3. Shell Programming and Scripting
I have 2 files, and I wish to count number of lines with this characteristic:
if any token at line x in file1, is similar to a token at line x in file2.
Here's an example:
file1:
ab, abc
ef
fg
file2:
ab
cd ef
gh
In this case I wish to get 3.
Note that token of file1 are... (3 Replies)
Discussion started by: Viernes
3 Replies
4. Shell Programming and Scripting
I have two files like this:
fileA.net
A
B
C
fileA.dat
1
2
3
and I want the output
output_expected
A 1
B 2
C 3
I know that the easier way is to do a paste fileA.net fileA.dat, but the problem is that I have 10,000 couple of files (fileB.net with fileB.dat; fileC.net with... (3 Replies)
Discussion started by: valente
3 Replies
5. Shell Programming and Scripting
Hi everyone,
I have two files (A and B) and want to combine them to one by always taking 10 rows from file A and subsequently 6 lines from file B. This process shall be repeated 40 times (file A = 400 lines; file B = 240 lines).
Does anybody have an idea how to do that using perl, awk or sed?... (6 Replies)
Discussion started by: ink_LE
6 Replies
6. Shell Programming and Scripting
Hi,
Pretty new to scripting sed awk etc. I'm trying to speed up calculations of disk space allocation. I've extracted the data i want and cleaned it up but i cant figure out the final step. I need to discover a Maximum value of 1 field where the value of another field is the same using awk
so... (4 Replies)
Discussion started by: imarcs
4 Replies
7. Shell Programming and Scripting
Hi,
I have a little problem with counting lines. I know similar topics from this forum, but they don't resolve my problem. I have file with lines like this:
2009-05-25 16:55:32,143 some text some regular expressions ect.
2009-05-25 16:55:32,144 some text.
2009-05-28 18:15:12,148 some... (4 Replies)
Discussion started by: marcinnnn
4 Replies
8. Shell Programming and Scripting
Hi Guys. I have tried the commands sort and join. But I couldn't able to to find the command for joining in a single line based on keys.My example inputs and outputs are like the following.
Help would be appreciated.:D
Input file
a1tabXXXXXXX
a2tabXXXXXXX
a6tabYYYYYYYYY
a71tabXXXXXXX... (7 Replies)
Discussion started by: repinementer
7 Replies
9. Shell Programming and Scripting
Hi everyone,
I need help with a merging problem. Basically, I have a file with several lines (in this example 9 lines) such as:
Amie, Jay, Sasha, Rob, Kay
Mia, Frank
Jay, Nancy, Cecil
Paul, Ked, Nancy, 17, Fred
14, 16, 18, 20
9, 11
12, Frank
18, Peter, 62
Nancy, 27
A delimiter is... (3 Replies)
Discussion started by: awb221
3 Replies
10. Shell Programming and Scripting
Dear Friends
myself Avinash working in bash shell
The problem goes like this
I have a file called work.txt
assume that
first colum=mac address
second colum= IP
third colum = port number
----------------------------------------
00:12:23:34 192.168.50.1 2
00:12:23:35 192.168.50.1 5... (2 Replies)
Discussion started by: avi.skynet
2 Replies