Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SPID Status definition for 'Sleeping' 1

Status
Not open for further replies.

daglugub37

Technical User
Oct 21, 2003
201
US
Does anyone know some good definitions for the status values in sysprocesses?

Mainly I am interested to know what "sleeping" really means and if it is possible that a spid can be processing in the DB while in sleep mode?

or what does runnable mean? Is it running or not?

Thanks for any input
 
A spid that is sleeping is an open connection that is waiting for a command to be sent from the client to the server.

A spid that is runnable is running the code last runable code submitted by the client to the server.

The status column is kind of strange (much like a lot of SQL Server).

Denny
MCSA (2003) / MCDBA (SQL 2000)

--Anything is possible. All it takes is a little research. (Me)

[noevil]
(My very old site)
 
ok sounds good. Lets say a spid is sleeping for a long time; and from the client point of view still processing...can a spid remain sleeping while it accepts non-continous commands...or would it switch to runnable; then sleeping; then runnable etc.
 
A spid can switch from sleeping to runnable and back many times. It's only going to be runnable while the command is actually running. Once it's done it goes back to sleeping until the next command is sent.

Denny
MCSA (2003) / MCDBA (SQL 2000)

--Anything is possible. All it takes is a little research. (Me)

[noevil]
(My very old site)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top