10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I'm trying to compare 2 files for differences in a selct number of fields. When differnces are found it will write the whole record of the second file including appending '|C' out to a delta file. Each record will have 20 fields, but only want to do comparison of 1st 15 fields. The 1st field of... (7 Replies)
Discussion started by: sljnk
7 Replies
2. Shell Programming and Scripting
Sample file record :
"20130617003","2013-06-18T07:00:03","OUTWARD","01001011","TEST PLC","","HFX834346364364","20130617","10","DUM87534758","","1.28","826","020201","65879278","","","","","","010101","56789","DUMMY... (3 Replies)
Discussion started by: bigbuk
3 Replies
3. Shell Programming and Scripting
How do you write a shell script to compare records with the same fields then keep the biggeer id number fields (field separate by a pipe)
1150| San Jose|8|15|7|2013-02-19 00:00:00.000|2013-02-20 00:00:00.000
1263|San Jose|8|15|7|2013-02-19 00:00:00.000|2013-02-20 00:00:00.000... (4 Replies)
Discussion started by: sabercats
4 Replies
4. UNIX for Dummies Questions & Answers
Hi All,
I need to delete the oldest file in folder when the file count in the folder exceed 6 ( i have a process that puts the source files into this folder )
E.x : Folder : /data/opt/backup
01/01/2012 a.txt
01/02/2012 b.txt
... (1 Reply)
Discussion started by: akshay01987
1 Replies
5. Linux
Hi all,
I want a perl program to delete the record and its contents from a file if there is no particular line in the record given that all records are separated by a blank line.
For example:
#100
abcd
efgh
hijk
123
klm
#200
abcd
efgh
hijk
klm
So, the pattern here is 123. If... (0 Replies)
Discussion started by: kaav06
0 Replies
6. Shell Programming and Scripting
Hi,
i want to generate print statement using awk.
i have 20+ and 30+ fields in each line
Now its priting only first eight fields print statement as output not all.
my record is as shown below filename
... (2 Replies)
Discussion started by: raghavendra.nsn
2 Replies
7. Shell Programming and Scripting
Hi,
I have a requirement in hand:
I have a file with millions of records say file 1.I have another file, say file 2 which has 2000 records in it. The requirement is to read file2 , and remove the read record from file 1 and move i to a seperate file, file 3.
For eg: Read file 2, get the... (5 Replies)
Discussion started by: kumara2010
5 Replies
8. Shell Programming and Scripting
:confused:
Hi Friends,
In the record below i have to make changes in the fields by putting the values stored in the temporary variables, x, y, z, p, q, r:
2) In the TBT record store the values in the various fields as:
a) X in a field position 51 to 56
b) Y... (5 Replies)
Discussion started by: kanu_pathak
5 Replies
9. Shell Programming and Scripting
Dear All ,
I have the query
cat temp.txt
|28-07-1997|IF_LEG_DCCT|TOV JV sdfsdfdsfdsfdsCLOSED* KIEV|381015280
I need to count the number of fields in this pipe-seperated file. I beleive this is possible via AWK command.
The in above file, output of the count should be 5....
Can some-one... (5 Replies)
Discussion started by: sureshg_sampat
5 Replies
10. Shell Programming and Scripting
Hi,
I'm trying this command - but get this error.
Do you guys have any workaround for this?
cat tf|sed 's/{//g'|sed 's/,//g'|awk '{for (i=1;i<=NF;i++) {if ($i == "OPTIME") {k = i + 2; print $i,$k}}}'
awk: record `2005 Jul 28 17:35:29...' has too many fields
record number 15
This is how... (3 Replies)
Discussion started by: chaandana
3 Replies