使用 psql 在 mac os 系统上登录,系统显示没有 psql 这个命令存在

解决方法如下:

将 postgresql 的 bin 目录添加到环境变量中即可

export PATH="/Applications/Postgres.app/Contents/Versions/9.5/bin:$PATH"

参考链接:

https://stackoverflow.com/questions/20928734/how-to-put-psql-on-the-path-when-using-postgres-app-on-os-x?rq=1

Mac OS -bash: psql: command not found 使用 psql 命令报错的更多相关文章

  1. RedHat中敲sh-copy-id命令报错:-bash: ssh-copy-id: command not found

    RedHat中敲sh-copy-id命令报错:-bash: ssh-copy-id: command not found 在多台Linux服务器SSH相互访问无需密码, 其中进入一台Linus中,对其 ...

  2. mac上执行sed的编辑 -i命令报错sed: 1: "test.txt": undefined label ‘est.txt’或sed: 1: "2a\test\": extra characters after \ at the end of a command

    问题一 sed编辑命令:[sed -i 's/a/b/g' test.txt]   报错:sed: 1: "test.txt": undefined label 'est.txt' ...

  3. scp命令报错-bash: scp: command not found

    # scp -bash: scp: command not found # which scp /usr/bin/scp # rpm -qf /usr/bin/scp openssh-clients- ...

  4. Mac 升级后idea执行git命令报错xcrun: error: invalid active developer path的解决办法

    报错 xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun ...

  5. Mac安装Mysql-python遇到的坑,被这俩报错反复摩擦:'my_config.h' file not found 和 IndexError: string index out of range

    最后Stackoverflow上面的大神解决了问题: Link brew install mysql brew unlink mysql brew install mysql-connector-c ...

  6. (3)mac下"-bash: mysql: command not found"解决方案

    针对 mysql: command not found 输入命令 $ ln -s /usr/local/mysql/bin/mysql /usr/bin 假如你人品不好,被打脸了,提示你权限不够: l ...

  7. Mac OS X中开启或关闭显示隐藏文件命令

    前言:之前一直用的都是 windows 系统的电脑,刚接触 Mac ,很多功能都不熟悉,写下博客记录一下,以防以后忘记,也给后来者提供方便. 命令行方式:显示隐藏文件: defaults write ...

  8. 解决mac os下mcss命令报错:env: node\r: No such file or directory

    标题无“转载”即原创文章,版权所有.转载请注明来源:http://besteam.im/blogs/article/31/. 我一直对字符界面有抵触感,即使会用vim,我的linux脚本(python ...

  9. react-native在mac上执行gradlew命令报错 ./gradlew: command not found

    这是因为react-native项目是windows上初始化,通过git clone到mac机器上后gradlew这个文件没有可执行权限,如图: 所以只需要给gradlew这个文件增加可执行权限就可以 ...

随机推荐

  1. Springboot中自已测试

    签到的测试,需要传入日期,签到7天可获得更多的积分, 构造7天前的签到记录,重写签到方法,进行构造数据 import cn.com.acxiom.coty.api.ws.bean.dto.PointD ...

  2. Spring Boot 配置文件中的花样

    原文:https://www.cnblogs.com/didispace/p/11002732.html 在快速入门一节中,我们轻松的实现了一个简单的RESTful API应用,体验了一下Spring ...

  3. [转]Linux网络 - 数据包的接收过程

    转, 原文: https://segmentfault.com/a/1190000008836467 ------------------------------------------------- ...

  4. solrconfig.xml配置文件

    部分来自http://www.jianshu.com/p/8cf609207497 一.总览 solr的配置重要的有三个:solr.xml.solrConfig.xml.schema.xml solr ...

  5. C#指针使用demo

    #region 使用指针检索数据值 //class program //{ // // 1.项目属性勾选“允许不安全代码” // // 2.使用unsafe 修饰符 // // 这里是将整个Main方 ...

  6. 马尔科夫链蒙特卡洛(MCMC) -- 学习笔记

    https://blog.csdn.net/m0_38088359/article/details/83480258 https://blog.csdn.net/shenxiaolu1984/arti ...

  7. DBUtils框架ResultSetHandler接口学习

    今儿在学习spring框架的时候,让我想起来之前做项目时一直搁置的一个问题,就是DBUtils框架的做数据库操作的使用,当时制作项目的时候就是通过实例打了一遍,由于时间原因也并没有仔细去了解这一方面. ...

  8. Kubernetes 学习16 RBAC

    一.概述 1.前面讲过,kubernetes的授权也是基于插件来实现而且用户访问时某一次操作经由某一授权插件检查能通过后就不再经由其它插件检查.然后由准入控制插件再做进一步后续的准入控制检查.那么在他 ...

  9. learning java 正则表达式

    var regStr = "Java is very good"; Matcher m = Pattern.compile("\\w+").matcher(re ...

  10. PHP CURL 错误码说明

    curl_setopt($ci, CURLOPT_HEADERFUNCTION, array($this, 'getHeader'));//一般不加 <?php return [ '1'=> ...