Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

SP_WHO2

Posted on 2008-06-16
5
Medium Priority
?
743 Views
Last Modified: 2008-06-30
Hi,
When SP_who2 is run,can it get the data from two weeks back or how is the time period determined?
is there a way to control the reult set time period? what does status RUNNABLE and Commands-- TASK Manger,AWAITING COMMAND,CHECKPOINT SLEEP mean?
0
Comment
Question by:crishna1
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 

Author Comment

by:crishna1
ID: 21798356
Alos, by running sp_who or sp_who2 has a chance of corrupting the database , is that true?
0
 

Author Comment

by:crishna1
ID: 21798497
i found the answers for various stages in status i asked in my question, now i need to know,
1)When SP_who2 is run,can it get the data from two weeks back or how is the time period determined?
2)by running sp_who or sp_who2 these is a chance of corrupting the database , is that true??
0
 
LVL 52

Expert Comment

by:Vitor Montalvão
ID: 21801849
Answer for your questions:
1) Those SP's gives you a snapshot of the moment you execute them. It's always about the present so you can't have data from a determined period.
2) False. Those SP's wouldn't corrupte databases. No chances at all for that.
0
 

Author Comment

by:crishna1
ID: 21804263
on question #1
how far back does it go and how is the time period based on or determined?  when i execute SP_WHO2 on one of my servers i see login/SPID's from 4-5 months back.
0
 
LVL 52

Accepted Solution

by:
Vitor Montalvão earned 750 total points
ID: 21813298
The limit it's the last time SQL Server service was restarted.
It will show you the current connections. If you have SPID's from 4-5 months ago, that means they was never disconnected. Maybe those are system processes (usually low process number).
0

Featured Post

 [eBook] Windows Nano Server

Download this FREE eBook and learn all you need to get started with Windows Nano Server, including deployment options, remote management
and troubleshooting tips and tricks

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
Recently we ran in to an issue while running some SQL jobs where we were trying to process the cubes.  We got an error saying failure stating 'NT SERVICE\SQLSERVERAGENT does not have access to Analysis Services. So this is a way to automate that wit…
Via a live example, show how to setup several different housekeeping processes for a SQL Server.
Viewers will learn how the fundamental information of how to create a table.

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question