SQLRNNR (3/5/2014)
GilaMonster (3/5/2014)
Potentially. I haven't tried this because I don't have a 2012 instance available. It's undocumented.
SELECT *
FROM sys.dm_db_database_page_allocations(DB_ID('<Database Name>'), NULL, NULL, NULL, 'DETAILED') dpa
WHERE allocated_page_file_id = @FileID AND allocated_page_page_id = @PageID
Should work. I might add database_id to the predicate.
No need, because the first parameter to the function limits the returned resultset to just the DB of interest. It's like index_physical_stats.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability