SCCM Reports – Last Hardware Scan Over 37 Days

I am working on SCCM reports a lot lately, here is the SQL statement for Last Hardware Scan Over 37 Days

SELECT dbo.v_R_System.AD_Site_Name0, dbo.v_R_System.Name0, dbo.v_R_System.User_Name0, dbo.v_R_System.Operating_System_Name_and0, dbo.v_R_User.department0, dbo.v_R_User.Mail0,
dbo.v_R_User.title0, dbo.v_GS_WORKSTATION_STATUS.LastHWScan
FROM dbo.v_GS_WORKSTATION_STATUS INNER JOIN
dbo.v_R_System ON dbo.v_GS_WORKSTATION_STATUS.ResourceID = dbo.v_R_System.ResourceID INNER JOIN
dbo.v_R_User ON dbo.v_R_System.User_Name0 = dbo.v_R_User.User_Name0
WHERE (DATEDIFF(day, dbo.v_GS_WORKSTATION_STATUS.LastHWScan, GETDATE()) >= 37)
order by 8

Leave a Reply