PostreSQL linux添加psql 命令

修改Linux環境變量sql

vi ~/.bash_profile

修改內容
PATH=$PATH:$HOME/.local/bin:$HOME/bin

export PATH
export PGHOME=/appl/postgres/pg9.6.1
export PGDATA=~/data
export PATH=$PATH:$HOME/bin:$PGHOME/bin

強制保存退出

:wq! 

從新加載環境變量文件

source ~/.bash_profile

能夠使用了 -d 數據庫

psql -U nswreporting -h CSLR76606u -d cnnswbc2
相關文章
相關標籤/搜索