ProgrammingWindows

Using Log Parser Studio to Get Requests Per Hour or Minute

After a load test of some web servers, I needed to have a look through the IIS logs to find out how many requests per minute were being generated on a specific web farm server.

The following Log Parser Studio query will group the results by minute, but you can adjust the QUANTIZE call to pass in 3600 rather than 60 if you wanted per-hour numbers.

SELECT
    QUANTIZE(TO_TIMESTAMP(date, time), 60) AS M, 
    COUNT(*) AS Total,  
    SUM(sc-bytes) AS TotBytesSent 
FROM
    '[LOGFILEPATH]'
WHERE
    date > '2016-04-23'
GROUP BY M 
ORDER BY M