From 52f5ad865d9a9f5a79da63d4d3adefc4e6a5915d Mon Sep 17 00:00:00 2001 From: Costa <47926492N@ICO.SCS.local> Date: Wed, 2 Mar 2022 14:00:12 +0100 Subject: [PATCH] =?UTF-8?q?Poder=20cambiar=20la=20ruta=20de=20la=20funci?= =?UTF-8?q?=C3=B3n=20sqlInitialize.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sqlFunctions.R | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sqlFunctions.R b/sqlFunctions.R index d73f10b..3a06d75 100644 --- a/sqlFunctions.R +++ b/sqlFunctions.R @@ -13,13 +13,13 @@ sqlLastDrop<-function(conn, tablename, droplast=1,dbtype=NULL){ sqlSave(conn, table, tablename = tablename, safer = F)} } -sqlInitialize<-function(){ +sqlInitialize<-function(ruta="ruta_database.R"){ library(tidyverse) library(RODBC) library(openxlsx) ## Conexión a la base de datos - source("ruta_database.R", encoding = "UTF-8") + source(ruta, encoding = "UTF-8") } sqlBackUp<-function(dbfile=file,conn=dta,bu.dir=NULL){