forked from gdbgeek/SQLLog
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathexample queries.sql
More file actions
31 lines (25 loc) · 1.24 KB
/
example queries.sql
File metadata and controls
31 lines (25 loc) · 1.24 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
select * from sdeadmin.RawLogs
where source = 'Basemap_FGDB_UNC.MapServer'
and message = 'End ExportMapImage'
select CONVERT(VARCHAR(10), time, 103) as Date, count(message) as Redraws
from sdeadmin.RawLogs
where source = 'Basemap_FGDB_UNC.MapServer'
and message = 'End ExportMapImage'
group by CONVERT(VARCHAR(10), time, 103)
order by CONVERT(VARCHAR(10), time, 103) desc
select distinct source
from sdeadmin.RawLogs
select COUNT(*) from sdeadmin.RawLogs
select distinct CONVERT(VARCHAR(10), time, 103) from sdeadmin.RawLogs
select CONVERT(VARCHAR(10), time, 103) as Date,datepart(hh,time) as "Hour", count(user)as "Draws", MIN(elapsed) as MinTime,MAX(elapsed) as MaxTime
from sdeadmin.RawLogs
where source = 'Basemap_FGDB_UNC.MapServer'
and message = 'End ExportMapImage'
group by CONVERT(VARCHAR(10), time, 103),datepart(hh,time)
order by CONVERT(VARCHAR(10), time, 103),datepart(hh,time) desc
select CONVERT(VARCHAR(10), time, 103) as Date,datepart(hh,time) as "Hour", count(user)as "Draws", MIN(elapsed) as MinTime,MAX(elapsed) as MaxTime
from sdeadmin.RawLogs
where source = 'Basemap_SQL.MapServer'
and message = 'End ExportMapImage'
group by CONVERT(VARCHAR(10), time, 103),datepart(hh,time)
order by CONVERT(VARCHAR(10), time, 103),datepart(hh,time) desc