Searching for a T-SQL query to find data from multiple SQL 2005 servers
I need a T-SQL query to find a list of all database names and sizes from multiple SQL 2005 servers that are connected in a local network. Does one exist?

Software/Hardware used:
ASKED: March 18, 2009  3:28 PM
UPDATED: March 18, 2009  9:01 PM

Answer Wiki:
To access another server using T/SQL you would need to have linked servers setup to each of your SQL Servers. Once you have the linked servers setup to access all the other servers run sp_helpdb remotely on each server. This will return the database name, size and other information about each database on the instance. <pre>EXEC RemoteServer.master.dbo.sp_helpdb</pre>
Last Wiki Answer Submitted:  March 18, 2009  9:01 pm  by  Denny Cherry   64,520 pts.
All Answer Wiki Contributors:  Denny Cherry   64,520 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _