| layout | api-command | ||||||
|---|---|---|---|---|---|---|---|
| language | Java | ||||||
| permalink | api/java/db_list/ | ||||||
| command | dbList | ||||||
| related_commands |
|
{% apibody %} r.dbList() → DbList {% endapibody %}
List all database names in the cluster. The result is a list of strings.
Example: List all databases.
List<?> dbList = r.dbList().run(connection, ArrayList.class).single();
if (dbList != null) {
dbList.forEach(System.out::println);
}