Solved

How do I get "Last Batch" time from EM's Process Info, via T-SQL.

Posted on 2006-07-03
2
322 Views
Last Modified: 2008-02-01
Hi.

I've got 20 different databases on 5 different SQL servers.

I have a web page which examines all the databases on all the servers, reporting who is logged in to a specific set of applications. This is all working fine.

I want to add to my web page (which is an on demand page, not a constant refresh and is used probably once or twice a week) the idle time, based upon the datetime of the last batch in the Process Info page of EM.

I see that I can use "exec sp_who" to get the data about who's connected to the DBS and which DB they are using. That's fine. But I already have that (to a degree).

I can't see how to get the last batch column.

2 of the servers are SQL7, the rest are SQL2K. We will be adding an SQL2K3 to the network soon.

Any ideas?


0
Comment
Question by:RQuadling
2 Comments
 
LVL 2

Accepted Solution

by:
ewahner earned 500 total points
ID: 17030217
sp_who2
0
 
LVL 40

Author Comment

by:RQuadling
ID: 17030236
Well. That was easy! No documentation in BOL though.
0

Featured Post

Control application downtime with dependency maps

Visualize the interdependencies between application components better with Applications Manager's automated application discovery and dependency mapping feature. Resolve performance issues faster by quickly isolating problematic components.

Question has a verified solution.

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

Nowadays, some of developer are too much worried about data. Who is using data, who is updating it etc. etc. Because, data is more costlier in term of money and information. So security of data is focusing concern in days. Lets' understand the Au…
Let's review the features of new SQL Server 2012 (Denali CTP3). It listed as below: PERCENT_RANK(): PERCENT_RANK() function will returns the percentage value of rank of the values among its group. PERCENT_RANK() function value always in be…
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
Via a live example, show how to shrink a transaction log file down to a reasonable size.

929 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

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now