Postgresql执行sql脚本

PG数据库需要执行外边的sql脚本方法:

1.可以将脚本拷贝到Navicat中,新建查询然后执行

 

2.或者登陆到数据库

su  - postgres

psql    -U   postgres   -p 19200  -d  sgg   -h  192.168.1.8  -f    /tmp/tmp.sql

 

posted @ 2022-04-15 20:21  中仕  阅读(138)  评论(0编辑  收藏  举报