knitr::opts_chunk$set( collapse = TRUE, comment = "#>", fig.path = "man/figures/README-", out.width = "100%" )
The goal of dreaconnect is to make connecting to database through R easier using drea database schema. Some basic utility functions such as listing tables in a database are also included.
You can install the development version of dreaconnect from GitHub with:
# install.packages("devtools") devtools::install_github("dormezil/dreaconnect")
This is a basic example which shows you how to solve a common problem:
Connect to EDW database. Be sure to assign connection to variable for later use.
library(dreaconnect) ## Connect to edw tables edw <- edw_connect()
Connect to DEVL database. Be sure to assign connection to variable for later use.
library(dreaconnect) ## Connect to devl tables #devl <- devl_connect()
List tables in database:
#list_tables() #options include "edw" and "devl". Defaults to "edw"
Connect to table:
#location_dim_db <- table_connect(edw, "location_dim") #vpk_wide_db <- table_connect(devl, "vpk_wide", "devl")
List EDW Table Dictionary
#edw_dictionary()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.