IIS日志分析工具

Log Parser Studio

由于IIS是UTC 0时,故要转为本地时间,使用这个函数 TO_LOCALTIME(TO_TIMESTAMP(date, time))

要使用函数,请在帮助文档里查询。帮助文档在:C:\Program Files (x86)\Log Parser 2.2\LogParser.chm 

一下例子是,获取全部的URI的最近访问时间

SELECT cs-uri-stem,
count(1) AS CNT,
MAX(TO_LOCALTIME(TO_TIMESTAMP(date, time))) AS LastVisitTime ,
MIN(TO_LOCALTIME(TO_TIMESTAMP(date, time))) AS EarlyVisitTime
FROM '[LOGFILEPATH]'
where cs-uri-stem like '%tnpm/%html%'
GROUP BY cs-uri-stem
order by cs-uri-stem

 

 

posted on 2022-02-22 14:08  水手paul2008  阅读(570)  评论(0编辑  收藏  举报