Skip to content

Instantly share code, notes, and snippets.

@alejio
Created August 1, 2015 18:08
Show Gist options
  • Save alejio/e0952720ee87d5acaaa3 to your computer and use it in GitHub Desktop.
Save alejio/e0952720ee87d5acaaa3 to your computer and use it in GitHub Desktop.
R: Save data frame to SQLite db
require("RSQLite")
# Set up database
drv <- dbDriver("SQLite")
tfile <- "Iowa.db"
con <- dbConnect(drv, dbname = "Iowa.db")
dbWriteTable(con, "data1", as.data.frame(data1))
dbDisconnect(con)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment