dbxInsert {dbx} | R Documentation |
Insert records
Description
Insert records
Usage
dbxInsert(conn, table, records, batch_size = NULL, returning = NULL)
Arguments
conn |
A DBIConnection object |
table |
The table name to insert |
records |
A data frame of records to insert |
batch_size |
The number of records to insert in a single statement (defaults to all) |
returning |
Columns to return |
Examples
db <- dbxConnect(adapter="sqlite", dbname=":memory:")
table <- "forecasts"
DBI::dbCreateTable(db, table, data.frame(id=1:3, temperature=20:22))
records <- data.frame(temperature=c(32, 25))
dbxInsert(db, table, records)
[Package dbx version 0.3.2 Index]