Sean Birchall
10/02/2022, 1:27 AMRPostgreSQL
in their R environment?
Keep getting the same error message in the screenshot, even if I install Postgres first.
sudo apt-get install libpq-dev
sudo sh -c 'echo "deb <http://apt.postgresql.org/pub/repos/apt> $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
wget --quiet -O - <https://www.postgresql.org/media/keys/ACCC4CF8.asc> | sudo apt-key add -
sudo apt-get update
sudo apt-get -y install postgresql
Rscript -e 'install.packages("RPostgreSQL", dependencies=TRUE, repos="<http://cran.rstudio.com/>")'
juanlu
10/03/2022, 8:29 AMReading state information...
The following additional packages will be installed:
libpq5
Suggested packages:
postgresql-doc-12
The following NEW packages will be installed:
libpq-dev libpq5
0 upgraded, 2 newly installed, 0 to remove and 155 not upgraded.
Need to get 254 kB of archives.
After this operation, 1,000 kB of additional disk space will be used.
Do you want to continue? [Y/n] Abort.
the apt-get install libpq-dev
call is missing a --yes
flag, otherwise the installation never proceeds.
this build script successfully installs RPostgreSQL:
#!/bin/bash
sudo apt-get install -y libpq-dev
Rscript -e 'install.packages("RPostgreSQL", dependencies=TRUE, repos="<http://cran.rstudio.com/>")'
let me know if that works for youSean Birchall
10/03/2022, 2:30 PM