splitting a string into an array using a time value

2008-10-14 Thread Joe Python
, tincidunt sed ] Note: there is an element corresponding to each time entry in the array I tried to use the pattern but its not working: pattern = r'(\d+/\d+/\d+ \d+:\d+:\d+ .+)' pat = re.compile(pattern) result = re.split(pat,s) - Joe Python -- http://mail.python.org

Apache log munging

2008-10-08 Thread Joe Python
I have a written a generator for an apache log which returns two types of information, hostname and the filename requested. The 'log' generator can be 'consumed' like this: for r in log: print r['host'], r['filename'] I want to find the top '100' hosts (sorted in descending order of total

Re: Apache log munging

2008-10-08 Thread Joe Python
): for file in filename: print host, all[host,file] print hosts[host] I was looking for a better option instead of building 'three' collections to improve performance. - Jo On Wed, Oct 8, 2008 at 2:15 PM, Joe Riopel [EMAIL PROTECTED] wrote: On Wed, Oct 8, 2008 at 1:55 PM, Joe Python