10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
hi,
Am trying to find a solution for finding a null column value inside a loop using array.
for eg:
two
three
five
From the above array myarray,myarray and myarray having null values. But when am trying to check that space using some condition its not working.
for (( i=0;... (4 Replies)
Discussion started by: rogerben
4 Replies
2. Shell Programming and Scripting
Please help me how can I display every nth field present in a "|" delimited file.
Ex: If a have a file with data as a|b|c|d|e|f|g|h|k|l|m|n
I want to display every 3rd feild which means the output should be
c
f
k
n
Please help me. (1 Reply)
Discussion started by: ngkumar
1 Replies
3. UNIX for Dummies Questions & Answers
Hi,
I have 2 files:
file1:
1 ia 2
1 mn 6
1 sd 11
2 ny 3
2 ma 10
3 wa 7
3 ca 8
file2
1 mi 3
1 wi 5
2 pa 4
3 id 6 (2 Replies)
Discussion started by: peanuts48
2 Replies
4. Shell Programming and Scripting
Hello,
I am trying to get a script to work which will find the maximum value of the fourth column and assign that value to all rows where the first three columns match.
For example:
1111 2222 AAAA 0.3
3333 4444 BBBB 0.7
1111 2222 AAAA 0.9
1111 2222 AAAA 0.5
3333 4444 BBBB 0.4
should... (8 Replies)
Discussion started by: jaysean
8 Replies
5. Shell Programming and Scripting
Can any one tell me how to get the second last column value from the text file, which has different record size for each record.
I know how to get the last column using awk and print statements, but I am unable to get the second last column value from the file. (4 Replies)
Discussion started by: naveen_sangam
4 Replies
6. Shell Programming and Scripting
Hi,
I need to find out the last column value from a text file which is delimited by a tab.
The issue here is the last column# for each record can be different i.,e, 1st record can have the last column as 15 and the second record can have the last column as "17".
I have to search a string... (3 Replies)
Discussion started by: naveen_sangam
3 Replies
7. Shell Programming and Scripting
Hi, been about 10 years since I've scripted, so very rusty and could use some quick help.
I have a file that contains data like such:
folder1 jondoe owner janedoe reader joeshmo none
folder2 jondoe none janedoe none joeshmo owner
folder3 jondoe owner
folder4 janedoe owner joeshmo... (7 Replies)
Discussion started by: drewpark
7 Replies
8. Shell Programming and Scripting
I have a small script where I want to see if a file exists & then delete the first line from it.
I have code to help me find if the file exists, but I am unsure as to how to then take in the answer and remove the first line from the flatfile:
This is what I have so far just to output if the... (3 Replies)
Discussion started by: fatalxkiss
3 Replies
9. Shell Programming and Scripting
I have a set of flatfiles which have columns delimited by #. How can a particular column be deleted in all the flatfiles. All flatfiles have same number of columns. (5 Replies)
Discussion started by: rsprabha
5 Replies
10. Shell Programming and Scripting
Hi,
I have a file with 3 columns in it that are comma separated and it has about 5000 lines. What I want to do is find the most common value in column 3 using awk or a shell script or whatever works! I'm totally stuck on how to do this.
e.g.
value1,value2,bob
value1,value2,bob... (12 Replies)
Discussion started by: Donkey25
12 Replies