When I probe sys.dm_exec_sessions (joining with other DMVs to get active-session info) I get the login_name column to be blank for a certain session.Yet, for the same spid, the Login shows up properly (not blank) when I execute "sp_who2 active".It also shows up properly in sys.sysprocesses.

What could be the reason for the faulty output of sys.dm_exec_sessions ?

Jack Corbett (8/30/2011)Hmm, interesting. Since I can't duplicate this I have no idea why it would be blank. The source for sysprocesses and sys.dm_exec_sessions are different so the difference must be in the source.

Thanks for responding, I'll see if I can find out something more about this.

Jack Corbett (8/31/2011)Posted this on Twitter and got an interesting question. Are you seeing this happen with a specific application like Access?

I get it for something called "Entity Framework", but I don't know much else about it. I would need to ask the devs about that.We don't use MS Access on that server.I also just saw a linked server query running on the server in question, linking to another server; login name was blank for that session as well.