Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/baileych/srcr
R package for managing database connections
https://github.com/baileych/srcr
Last synced: 8 days ago
JSON representation
R package for managing database connections
- Host: GitHub
- URL: https://github.com/baileych/srcr
- Owner: baileych
- License: other
- Created: 2019-12-03T20:01:27.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2024-05-12T17:39:24.000Z (7 months ago)
- Last Synced: 2024-10-13T12:51:53.975Z (about 2 months ago)
- Language: R
- Size: 59.6 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.Rmd
- Changelog: NEWS.md
Awesome Lists containing this project
- jimsghstars - baileych/srcr - R package for managing database connections (R)
README
---
output: github_document
---```{r, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-",
out.width = "100%"
)
```# srcr
[![R build status](https://github.com/baileych/srcr/workflows/R-CMD-check/badge.svg)](https://github.com/baileych/srcr/actions)
[![CRAN status](https://www.r-pkg.org/badges/version/srcr)](https://CRAN.R-project.org/package=srcr)Connecting to databases requires boilerplate code to specify
connection parameters and to set up sessions properly with the DBMS.
This package provides a simple tool to fill two purposes: abstracting
connection details, including secret credentials, out of your source
code and managing configuration for frequently-used database connections
in a persistent and flexible way, while minimizing requirements on the
runtime environment.## Installation
You can install the current version of srcr from
[CRAN](https://cran.r-project.org/package=srcr). Development
versions are hosted on [GitHub](https://github.com/baileych/srcr), and can be
installed with:``` r
require(devtools)
install_githubpackages('baileych/srcr')
```## Example
This is a basic example which shows you how to solve a common problem:
```{r example, eval=FALSE}
library(srcr)
db <- srcr(basenames = 'my_project_config',
allow_post_connect = c('sql', 'fun'))
```