January 9, 2015 at 1:05 pm
I am connected to a SQL server using windows auth.
My query window was open for a whole day but active (not disconnected).
It's spid (as seen in bottom right of SSMS) is 61.
When I ran sp_who2 61
from a new query window on same server, it showed some other hostname and login than mine.
Anyone else experience this ?
Can two processes share a spid ?
Is SSMS showing wrong spid for current query, or is sp_who2 showing wrong data ?
January 9, 2015 at 1:08 pm
I know you explicitly said same server, but that's too weird.
so theres no chance you are in a multi server environment, and the window you look at is test/development, but the sp_who2 was run on production?
Lowell
January 9, 2015 at 1:22 pm
Are you sure that spid was still active?
For best practices on asking questions, please read the following article: Forum Etiquette: How to post data/code on a forum to get the best help[/url]
January 9, 2015 at 1:58 pm
I thought I was going crazy / blind too.
So had a colleague look at my screen while i hit the NEW-QUERY button (which by default opens a same server-db connection),
we explicitly checked it was on the same server & login,
then ran sp_who2 61, and it showed a front-end's hostname, rather than my laptop name.
@Alvin,
Yes, I was actively running queries from that window, a minute before I checked sp_who2.
The only thing I can imagine is, since I had the connection open for a while, maybe SQL or SSMS was showing me the wrong spid..
January 9, 2015 at 2:06 pm
The only thing I can imagine is, since I had the connection open for a while, maybe SQL or SSMS was showing me the wrong spid..
This would make sense.
For best practices on asking questions, please read the following article: Forum Etiquette: How to post data/code on a forum to get the best help[/url]
January 9, 2015 at 3:49 pm
I'd try SELECT @@SPID as well as selecting from sys.dm_exec_requests, sys.dm_exec_connections (I think) to see what's there.
Still sounds a little odd.
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
Viewing 6 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply