Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


How can I know what query is executing by by a particural
user? (using sp id or any othe way.)

Answers were Sorted based on User's Feedback



How can I know what query is executing by by a particural user? (using sp id or any othe way.)..

Answer / suvendu

SELECT *
FROM Master.dbo.sysprocesses
WHERE DBID NOT IN (1,2,3,4) -- Master, Tempdb, Model, MSDB
AND spid > 50
ORDER BY spid DESC

Is This Answer Correct ?    2 Yes 0 No

How can I know what query is executing by by a particural user? (using sp id or any othe way.)..

Answer / prem

DBCC INputbuffer(spid)- Displays the last statement sent
from a client to an instance of Microsoft SQL Server 2005.

First 256 characters only will be displayed.


SQL statements can also be captured by running a profiler.

Is This Answer Correct ?    2 Yes 2 No

Post New Answer

More SQL Server Interview Questions

Explain comment on transactions?

0 Answers  


Give an example of why you would want to denormalize a database

0 Answers  


If we delete pack Spec what will be the status of pack Body ?

0 Answers   Nagarro,


how do you implement one-to-one, one-to-many and many-to-many relationships while designing tables? : Sql server database administration

0 Answers  


When do you create cluster and noncluster index?

5 Answers   Satyam,


what are defaults? Is there a column to which a default can't be bound? : Sql server database administration

0 Answers  


What is log in sql server?

0 Answers  


Does any body please help me what question's have asked for SSRS in the interview?

0 Answers  


What is the native system stored procedure to execute a command against all databases?

0 Answers  


What is difference between table aliases and column aliases? Do they affect performance?

0 Answers  


What are the differences between local and global temporary tables?

0 Answers  


what is denormalization? : Sql server database administration

0 Answers  


Categories