The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM



View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
  #3 (permalink)  
Old 08-30-2007
radoulov's Avatar
radoulov radoulov is offline
addict
 

Join Date: Jan 2007
Location: Milano, Italia/Варна, България
Posts: 2,020
Code:
awk '{x[substr($0,9)]++;y[substr($0,9)]=$1}END{
	for(i in x)
printf "%s\nThis Error was reproduced %d times\n",y[i]i,x[i]
}' logfile
As always, use nawk or /usr/xpg4/bin/awk on Solaris.
Reply With Quote