Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am doing analysis on a web log. The fields I have are:
UserName,
TimeStamp,
Action,
SessionID (Identifier that tracks an active session)
Before a user logs in, we track their UserName as 'NA' and when they log in their UserName switches to their actual login name. However, we also run scripts to test are servers that are also stored with the UserName 'NA'. Could you guys help me come up with the Where statement that would include the UserName 'NA' when there is another UserName within that SessionID and eliminate the UserNames 'NA' when it is the only UserName in that SessionID?
Thanks in advance,
Eric
Can you provide some sample data and required output?
Best guess without sample data.
QualifiedSessions:
LOAD SessionId
where UseridCount>1
;
LOAD
SessionId,
count(UserName) as UseridCount
FROM weblogs
GROUP by SessionId
;
SessionLogs:
LOAD *
FROM weblogs
WHERE exists(SessionId)
;
DROP TABLE QualifiedSessions;
-Rob