我正在使用 PostgreSql 版本:
postgres=# select version();
version
-------------------------------------------------------------
PostgreSQL 9.2.4, compiled by Visual C++ build 1600, 64-bit
(1 row)
我已经连接到数据库...。现在我在数据库postgres=#
中,我想断开它并返回数据库...。newdb=#
newdb=#
postgres=#
这该怎么做 ?
我试过了disconnect newdb;
但它的错误是::
postgres=# create database newdb;
CREATE DATABASE
postgres=# \c newdb;
WARNING: Console code page (437) differs from Windows code page (1252)
8-bit characters might not work correctly. See psql reference
page "Notes for Windows users" for details.
You are now connected to database "newdb" as user "postgres".
newdb=# disconnect newdb;
ERROR: syntax error at or near "disconnect"
LINE 1: disconnect newdb;
^
newdb=#
它不起作用有没有其他方法可以做到这一点,或者我做错了什么!!