#' @export
sqlCreateTable <- function(df,table_name, return_query = F){
colnames(df) %<>% gsub("[[:punct:][:space:]]","_",x=.)
query <- DBI::sqlCreateTable(DBI::ANSI(), table_name, df)[[1]] %>%
gsub("\"","`",x=.)
if(return_query) cat(query)
dbSendQuery(con, query)
dbClearResult(dbListResults(con)[[1]])
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.