
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-19-2013 06:00 PM
Hi
I created a report in which I basically display hostname, ip address & UPTIME.
The uptime showup me the info in minutes is there is a way to change the format to hours or days instead?
I created a report in which I basically display hostname, ip address & UPTIME.
The uptime showup me the info in minutes is there is a way to change the format to hours or days instead?
Labels:
- Labels:
-
Archive
1 REPLY 1

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-19-2013 06:36 PM
Uptime data is actually stored in seconds. You can perform calculations with SQL to get the uptime in minutes, hours or days.
Ceiling (tblAssets.Uptime / 60 ) -> uptime in minutes
Ceiling (tblAssets.Uptime / 60 / 60 ) -> uptime in hours
Ceiling (tblAssets.Uptime / 60 / 60 / 24 ) -> uptime in days
A sample report that lists the uptime in hours can be seen below.
Ceiling (tblAssets.Uptime / 60 ) -> uptime in minutes
Ceiling (tblAssets.Uptime / 60 / 60 ) -> uptime in hours
Ceiling (tblAssets.Uptime / 60 / 60 / 24 ) -> uptime in days
A sample report that lists the uptime in hours can be seen below.
Select Top 1000000 tblAssets.AssetID,
tblAssets.AssetName,
tsysAssetTypes.AssetTypename,
tsysAssetTypes.AssetTypeIcon10 As icon,
tblAssets.IPAddress,
tblAssets.Lastseen,
Ceiling(tblAssets.Uptime / 60 / 60) As Uptime
From tblAssets
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysAssetTypes On tsysAssetTypes.AssetType = tblAssets.Assettype
Where tblAssetCustom.State = 1
Order By tblAssets.IPNumeric
