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
相关文章
相关标签/搜索