connect: Creates connection to DPCG database To be reused in the...

View source: R/dbconnection.R

connectR Documentation

Creates connection to DPCG database To be reused in the subsequent class and markdown SQL chunks.

Description

Creates connection to DPCG database To be reused in the subsequent class and markdown SQL chunks.

Usage

connect(
  hostname = "localhost",
  dbname = "surveys",
  port = "55431",
  user = "johnny_local",
  pwd
)

Arguments

hostname

DB hostname or localhost if ssh tunnel is used

dbname

Usually surveys for DPCG

port

55431 for Postgres-XZ

user

DB user, i.e. nienarto_local

pwd

optional password. Not needed if .pgpass is up to date (and it should be!)

Value

DB connection object to be reused in SQL chunks and other calls

Examples

## Not run: connect(user="nienarto_local", port=55431)

yazun/dpcgR documentation built on Feb. 2, 2024, 7:12 p.m.