Even better is LogParser, which lets you do SQL queries against just about any data format you'll find in a file on Windows. It's been around for a decade and continues to be improved.
http://technet.microsoft.com/en-us/scriptcenter/dd919274.asp...
http://technet.microsoft.com/en-us/scriptcenter/dd919274.asp...