Writes an Arrow Table or RecordBatch directly to DuckLake.
This provides an alternative to db_write() when your data is already
in Arrow format.
Usage
db_write_arrow(
data,
schema = "main",
table,
mode = c("overwrite", "append"),
commit_author = NULL,
commit_message = NULL
)See also
db_write() for writing data.frames with more options,
db_read_arrow() for reading as Arrow
Examples
if (FALSE) { # \dontrun{
db_connect(...)
# Write Arrow Table
arrow_tbl <- arrow::arrow_table(id = 1:3, value = c(10, 20, 30))
db_write_arrow(arrow_tbl, table = "metrics")
# Write from parquet file
arrow_tbl <- arrow::read_parquet("data.parquet")
db_write_arrow(arrow_tbl, table = "imports", mode = "append")
} # }