Quantcast
Channel: Symantec Connect
Viewing all articles
Browse latest Browse all 22530

Help creating a SQL report for user logon and logoff times for specific OU

$
0
0
I need a solution

I've been trying to create a SQL query to get a report on user logon and logoff times for a specific OU.

I've tried just about everything and I'm out of ideas.

I've got this to get the logon report:

 

SELECT    DISTINCT T1.[Guid] AS 'Guid',
        T1.[Name] AS 'Name',
        T0.[Event] AS 'Event',
        T0.[User] AS 'User',
        T0.[Domain] AS 'Domain',
        T0.[Time] AS 'Time'
FROM [vResourceEx] T1
INNER JOIN [Evt_AeX_Client_LogOn] T0 ON T1.[Guid] = T0.[_ResourceGuid]
WHERE T1.[ResourceTypeGuid] = '493435F7-3B17-4C4C-B07F-C23E7AB7781F'
  AND T1.[IsManaged] = 1
  AND CONVERT(CHAR(10),T0.[Time],101) BETWEEN '01/31/2013' AND '01/31/2013'
  AND CONVERT(CHAR(10),T0.[Time],114) BETWEEN '00:00' AND '23:59'
ORDER BY T0.[Time] ASC
 
But I need to only do the report on a certain OU.  Any help would be appreciated.
 
Thanks

Viewing all articles
Browse latest Browse all 22530

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>