我有一个R闪亮的服务器,它也托管一个PostgreSQL数据库。但是,我无法将R与Postgres连接。
这是我的R脚本:
library("dplyr")
library("RPostgreSQL")
con <- dbConnect(PostgreSQL(), dbname = "___", host="localhost", port="___", user="___", password="___")
使用Rscript "skript.R"
我收到此错误:
Error in postgresqlNewConnection(drv, ...) :
RS-DBI driver: (could not connect _____@localhost:___ on dbname "versuch1": FATAL: Ident authentication failed for user "_____"
)
Calls: dbConnect -> dbConnect -> postgresqlNewConnection -> .Call
Execution halted
我做错了什么。任何提示?