小编Ame*_*ina的帖子

如何从 PostgreSQL 中获取当前数据库的名称?

\c <database_name>在 PostgreSQL 中使用将连接到指定的数据库。

如何确定当前数据库的名称?

进入:

my_db> current_database();
Run Code Online (Sandbox Code Playgroud)

产生:

ERROR:  syntax error at or near "current_database"
LINE 1: current_database();
Run Code Online (Sandbox Code Playgroud)

postgresql psql

143
推荐指数
4
解决办法
18万
查看次数

标签 统计

postgresql ×1

psql ×1