列出复合数据库企业版Aura 不可用
您可以使用 SHOW DATABASES 命令列出组合数据库。组合数据库在结果集的 type 列中会显示为 composite 类型。
查询
SHOW DATABASES
结果
+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | name | type | aliases | access | address | role | writer | requestedStatus | currentStatus | statusMessage | default | home | constituents | +----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | "library" | "composite" | [] | "read-only" | "localhost:7687" | NULL | FALSE | "online" | "online" | "" | FALSE | FALSE | ["library.sci-fi"] | | "neo4j" | "standard" | [] | "read-write" | "localhost:7687" | "primary" | TRUE | "online" | "online" | "" | TRUE | TRUE | [] | | "sci-fi" | "standard" | ["library.sci-fi"] | "read-write" | "localhost:7687" | "primary" | TRUE | "online" | "online" | "" | FALSE | FALSE | [] | | "system" | "system" | [] | "read-write" | "localhost:7687" | "primary" | TRUE | "online" | "online" | "" | FALSE | FALSE | [] | +----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
有关该命令返回的所有列的说明、SHOW DATABASE 命令的过滤方式以及执行该命令所需权限的详细信息,请参阅 列出标准数据库。
对于组合数据库,constituents 列尤为重要,因为它列出了构成该组合数据库的所有别名。
查询
SHOW DATABASE library YIELD name, constituents
结果
+--------------------------------+ | name | constituents | +--------------------------------+ | "library" | ["library.sci-fi"] | +--------------------------------+