dbpath_build: Build a dbpath object

View source: R/dbpath_build.R

dbpath_buildR Documentation

Build a dbpath object

Description

Builds a dbpath() object from its parts. All parts are optional other than dialect. To create a database URL, use format() on the resulting dbpath object.

Usage

dbpath_build(
  dialect,
  driver = NULL,
  username = NULL,
  password = NULL,
  host = NULL,
  port = NULL,
  database = NULL,
  params = NULL
)

Arguments

dialect, driver

The SQL database dialect and optional R driver package to use with this dialect.

username, password

Optional username and password

host, port

Optional host and port

database

The name of the database

params

A named list of query parameters or a query string. For example, either list(foo = "bar", name = "value") or foo=bar&name=value.

Value

A dbpath() object.

Examples

dbpath_build("postgres", host = "localhost", port = 5432, database = "money")


machow/dbpath documentation built on Dec. 30, 2022, 8:52 p.m.