How to Browse (or) view objects and there code in mssqlsystemresource Database

How to Browse (or) view mssqlsystemresource Database.

1. Stop the SQL Server service
    Copy the mssqlsystemresource.MDF and mssqlsystemresource.LDF to a new path (This
   two files will be in same path where master databse is located).
   Start the SQL Server Service
   Ues the following command to attach the data and log file as a new user database.

   EXEC sp_attach_db
   'mssqlsystemresource _Copy', '<Path where you copied>\resource_copy.mdf',
   '<Path where you copied>\resource_copy.ldf'
   Now you browse through all the system objects and there code.


1. Start SQL Server in single user mode.

2. Open SSMS and connect using DAC (ADMIN) Connection and change DB context to “mssqlsystemresource”.

  use mssqlsystemresource

3. Query Resource DB objects.



Karthick P.K

Comments (2)

  1. yup says:

    Here is what I did

    >>Started SQL 2005 in single user mode.

    –net start mssql$s9c -m

    >>Connected as DAC

    –sqlcmd -E -S .s9c -A

    >>Check all the databases

    –Select * from sys.sysdbreg

    While I can see dbid 32767 or mssqlsystemresource in the output rows an attemt to get inside failed. This was the sql statement used and the output

    >>use mssqlsystemresource fails

    –Msg 911, Level 16, State 1, Server WIN-RCMI11NRUK0S9C, Line 1

    –Could not locate entry in sysdatabases for database 'mssqlsystemresource'. No entry found with that

    –name. Make sure that the name is entered correctly.

    Any idea if can avoid going through sysdatabases for this ?

    Its on sql DEV 2005 – 9.00.5057 (X64) Mar 25 2011 13:33:31 on Windows NT 6.1 (Build 7601: Service Pack 1)

Skip to main content