23 August 2008

WQL Query list reboot date timestamp X Days


WQL Query to list all of the machines that have a reboot date timestamp of more than x Day's

Select

Sms_R_System.Name,

Sms_G_System_Operating_System.LastBootUpTime

From SMS_R_System

Inner Join Sms_G_System_Operating_System

On Sms_G_System_Operating_System.ResourceId = Sms_R_System.ResourceId

Where DatePart(DD,Sms_G_System_Operating_System.LastBootUpTime) >= X

Enjoy,

Paddy


No comments: