How to retrieve the names of all Nonsystem-databases from SQL Server 2000 using a TSQL query?
I have anticipated:
SELECT *
FROM sysdatabases
where dbid >4
order by dbid
it does not seem to be reliable.
Anything else?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
From SQL Server 2000 Books Online:
So, master, model, msdb and temp are all the system databases. Your query can safely exclude just these.