OU Count of PCs not reporting within 1 day

SELECT
    OU.System_OU_Name0,
    count(*) as ‘Count’
FROM 
    dbo.v_GS_WORKSTATION_STATUS    as WS,
    dbo.v_R_System as SYS,
    dbo.v_RA_System_SystemOUName as OU
Where
    SYS.ResourceID = OU.ResourceID
    and SYS.ResourceID = WS.ResourceID
    and Datediff(dd,WS.LastHWScan, getdate()) > 1
group by
    OU.System_OU_Name0
order by
    OU.System_OU_Name0

Leave a Reply

Your email address will not be published. Required fields are marked *