Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

A list of SQL Server Databases

Posted on 2004-08-11
2
213 Views
Last Modified: 2010-05-02
Hello
I have a DECommand that connects to SQL Server.
I would like to know how I can get a list of databases in that SQL Server at trhe run-time.
Thanks.
0
Comment
Question by:v_shalchian
2 Comments
 
LVL 8

Accepted Solution

by:
SNilsson earned 125 total points
ID: 11780929

This Sql statement return all databas names on the server:


SELECT Name FROM master..sysdatabases
0
 

Expert Comment

by:DMV
ID: 15152510
All right I ran the following:

   SELECT Name FROM master..sysdatabases

and received 8 database rows, one of which is blank.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question