June 25, 2002 at 4:46 am
Is there a way of getting table-name from the given PageID?
For example, "SELECT waitresource FROM sysprocesses" gives the result
"PAG:
7:1:3630", and 3630 is the PageID. I need to determine the corresponding
the
table-name.
Prakash
Prakash Heda
Lead DBA Team - www.sqlfeatures.com
Video sessions on Performance Tuning and SQL 2012 HA
June 25, 2002 at 6:39 am
What SQL Server version are you using?
Thomas Rushton
blog: https://thelonedba.wordpress.com
June 25, 2002 at 11:31 pm
SQL 2K WITH SP2 ON W2K ADVANCED SERVER
Prakash
Prakash Heda
Lead DBA Team - www.sqlfeatures.com
Video sessions on Performance Tuning and SQL 2012 HA
June 28, 2002 at 2:57 pm
I would usually use DBCC PAGE to view the page in question; the page header indicates what object the page belongs to. For example, given the information you provided, I would execute:
DBCC TRACEON(3604)
GO
DBCC PAGE (7, 1, 3630)
GO
DBCC TRACEOFF(3604)
GO
The result set will be divided into several sections. Look for the "Page Header" section, and in that section look for "m_objId"; the value following that is the object id of the object that owns the particular page. Use:
SELECT OBJECT_NAME(object_id)
replacing object_id with the object id you got from "m_objId" to get the name of the object that owns the page in question.
Matthew Burr
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply