diff --git a/Docs/sqlFunctions-doc.Rmd b/Docs/sqlFunctions-doc.Rmd index a6d750c..5d50554 100644 --- a/Docs/sqlFunctions-doc.Rmd +++ b/Docs/sqlFunctions-doc.Rmd @@ -1,12 +1,16 @@ --- title: "sqlFunctions-Doc" -output: html_document +output: + html_document: + toc: true + toc_depth: 2 --- ```{r setup, include=FALSE} knitr::opts_chunk$set(echo = TRUE) ``` +--- ## sqlDropLast @@ -43,3 +47,41 @@ sqlDropLast<-function(conn, tablename, droplast=1){ sqlSave(conn, table, tablename = tablename, safer = F) } ``` + +--- + +## sqlInitizalize + +### Description +Loads required libraries and gets the db location. + +### Usage +sqlInitialize() + +### Arguments +Argument|Description +---|--- + +### Details +Loads required libraries and gets the db location from "ruta_database.R" file. + +### Value +Invisibly for success (and failures cause errors). + +### Examples +```r +sqlInitialize() +``` + +### Function +```r +sqlInitialize<-function(){ + library(tidyverse) + library(RODBC) + library(openxlsx) + + ## Conexión a la base de datos + source("ruta_database.R", encoding = "UTF-8") +} +``` + diff --git a/Docs/sqlFunctions-doc.html b/Docs/sqlFunctions-doc.html index 63ad704..f9a4661 100644 --- a/Docs/sqlFunctions-doc.html +++ b/Docs/sqlFunctions-doc.html @@ -167,7 +167,14 @@ pre code { +
Loads required libraries and gets the db location.
+sqlInitialize()
+Argument | +Description | +
---|
Loads required libraries and gets the db location from “ruta_database.R” file.
+Invisibly for success (and failures cause errors).
+sqlInitialize()
+sqlInitialize<-function(){
+ library(tidyverse)
+ library(RODBC)
+ library(openxlsx)
+
+ ## Conexión a la base de datos
+ source("ruta_database.R", encoding = "UTF-8")
+}