Using LogParser 2.2 to Parse IIS Logs and Other Logs
page 6 of 13
by Sudeep G
Average Rating: 
Views (Total / Last 10 Days): 88420/ 136

Scenario 4: Combining Fields

Now you wish to trace requests to a specific URL and want to get the protocol status and protocol sub-status combined.

Listing 17

LogParser -i:IISW3C -o:DataGrid "SELECT cs-uri-stem, STRCAT(TO_STRING(sc-status), 
STRCAT('.',TO_STRING(sc-substatus))) as Status FROM ex080620.log" -q:ON 

This will find all requests that failed with a status code of HTTP 500.

Listing 18

LogParser -i:IISW3C -o:DataGrid "SELECT cs-uri-stem,  sc-status as Status FROM  
ex080620.log WHERE Status='500'" -q:ON

View Entire Article

User Comments

No comments posted yet.

Product Spotlight
Product Spotlight 

Community Advice: ASP | SQL | XML | Regular Expressions | Windows

©Copyright 1998-2024  |  Page Processed at 2024-06-17 6:59:53 PM  AspAlliance Recent Articles RSS Feed
About ASPAlliance | Newsgroups | Advertise | Authors | Email Lists | Feedback | Link To Us | Privacy | Search