Log Parser

Wednesday 24 August 2005This is 19 years old. Be careful.

Jeff Atwood extolls the virtues of Microsoft Log Parser. It provides a SQL syntax for querying log files of diverse heritages. It sounds very cool, and damn handy. From a quick look through the source he provides, I didn’t see how to plug in new input parsers, though the architecture diagram he shows has a block for them. With CSV and XML inputs available, I guess you could transform anything you like into something it could eat even without plugins.

Comments

[gravatar]
To plug in a custom input parser, you write a COM object in the language of your choice that implements the ILogParserInputContext COM interface . There's a section in the help file on this, and some samples that install with the application. And if you get stuck, you can come on over to http://www.logparser.com and ask for help - the app's developer hangs around the forum and answers questions.
[gravatar]
LAME. Who wants to write a friggin' COM object just to define a log format? Typical microsoft. You should be able to just write an XML document that defines the log format.

Which is funny, because I'm working on a project at home with a very similar dynamic... you have an XML document which defines how to build a parser for other XML documents.
[gravatar]
Yeah, COM is lame. No argument there.

That said, you can download a sample C# project from the repository section of Mike's site that has the skeleton ILogParserInputContext COM interface already plugged in for you...

Add a comment:

Ignore this:
Leave this empty:
Name is required. Either email or web are required. Email won't be displayed and I won't spam you. Your web site won't be indexed by search engines.
Don't put anything here:
Leave this empty:
Comment text is Markdown.