Solved

Sp_who2

Posted on 2004-09-03
4
758 Views
Last Modified: 2010-05-18
Hi,

Where or How does the  SP_WHO2 gets the information for which program the user is running?

EX:

54  sleeping   NT AUTHORITY\SYSTEM     HOUDB .     msdb     AWAITING COMMAND     31 0     05/14 09:49:55     SQLAgent - Generic refresher                  
55  sleeping   NT AUTHORITY\SYSTEM     HOUDB  .    msdb     AWAITING COMMAND     14420526     09/03 11:26:34          SQLAgent -Alert Engine                      
56  sleeping   ABC_SYS                    SPERRYWS   . ABC_ENERGY18     AWAITING COMMAND     125687 09/02 18:34:08  Gas Modules                                
57 sleeping    ABC_SYS                    SPERRYWS   . ABC_ENERGY18     AWAITING COMMAND     5000 09/02 17:07:30      Financial Bucket    

The one at the very end is programname which i am interested in.

many thanks.
0
Comment
Question by:crishna1
4 Comments
 
LVL 14

Accepted Solution

by:
Jan_Franek earned 500 total points
ID: 11976075
This info is sent from client at login. It's stored into master.dbo.sysprocesses system table, that is queried by sp_who2
0
 
LVL 34

Expert Comment

by:arbert
ID: 11976528
Agreed--when the application is programmed, you, as the programmer, can change the application name......

if you really wanna see what's going on, run this in query analyzer:

use master
go
sp_helptext sp_who2
0

Featured Post

U.S. Department of Agriculture and Acronis Access

With the new era of mobile computing, smartphones and tablets, wireless communications and cloud services, the USDA sought to take advantage of a mobilized workforce and the blurring lines between personal and corporate computing resources.

Question has a verified solution.

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

Introduction In my previous article (http://www.experts-exchange.com/Microsoft/Development/MS-SQL-Server/SSIS/A_9150-Loading-XML-Using-SSIS.html) I showed you how the XML Source component can be used to load XML files into a SQL Server database, us…
Ever wondered why sometimes your SQL Server is slow or unresponsive with connections spiking up but by the time you go in, all is well? The following article will show you how to install and configure a SQL job that will send you email alerts includ…
Via a live example combined with referencing Books Online, show some of the information that can be extracted from the Catalog Views in SQL Server.
Via a live example, show how to set up a backup for SQL Server using a Maintenance Plan and how to schedule the job into SQL Server Agent.

770 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