Skip to main content

Commands: How to get names of all databases on a server?

To download all available database names from a server, use the GetDatabaseNames command from GlobalAdmin.

Syntax

string[] GetDatabaseNames(int pageSize, int start = 0);
Parameters
pageSizeintMaximum number of records that will be downloaded
startintNumber of records that should be skipped. Default: 0
Return Value
string[]Names of all databases on a server

Example

string[] databaseNames = store
.DatabaseCommands
.GlobalAdmin
.GetDatabaseNames(10);