Search Results

Search: Posts Made By: killerbee
2,183
Posted By pravin27
Could this help you ? awk...
Could this help you ?


awk 'NR==FNR{if(/^Group/){g=$3;i=1;next}if(i==2){a[g]=$1}i++;next}
{if(/^Group/){k=$3;j=1;print;next}if(j==3){$1+=a[k];$2+=a[k]}print;j++}' data2.txt data1.txt
Showing results 1 to 1 of 1

 
All times are GMT -4. The time now is 06:36 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy