Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2008 Forums
 Transact-SQL (2008)
 Query question

Author  Topic 

fchachar
Starting Member

15 Posts

Posted - 2012-11-08 : 16:30:09
This sound stupid but I was wondering if anyone of you could help me achieve this goal.

I have a list of users I would say about 4500 so I am using this Query.

SELECT Username, MAX(TimeEntered) as [Last Accessed System]
FROM AuditEvent
LEFT JOIN AuditType ON AuditEvent.TypeID = AuditType.TypeID
Where Username IN
-- There are about 4500 Users here.
('User1', 'User2', 'User3', 'Usern')
GROUP BY Username
ORDER BY [Last Accessed System]

The results return with 3120 transactions, my question is how do I find out about those who missed out of 4500. 1380 did not make any transaction or create any entry in the Table, I am interested to know the usernames of 1380 users. How do I get that?

Thanks.

bandi
Master Smack Fu Yak Hacker

2242 Posts

Posted - 2012-11-09 : 00:31:41
Do you have 4500 users Details Table?

Write Cross checking Logic to find 1380 users by the help og UserDetails Table..........



--
Chandu
Go to Top of Page
   

- Advertisement -