Description Usage Arguments Details Examples
This is a convenience wrapper for the DBI::dbWriteTable function.
1 | upload_table(.conn, name, data, ...)
|
.conn |
The connection object (needed to drop the table before 'compute' is called) |
name |
The name of the desired table. Can use dplyr::in_schema() to specify a table in a different schema than the one that was defined in the connection. Note: will be dropped and recreated if a table already exists. |
data |
Incoming tibble/data.frame |
... |
additional parameters passed through to DBI::dbWriteTable(), ie. field.types, overwrite = TRUE, temporary = TRUE, append = TRUE. |
Known issues: varchar fields are set to a length of 255 characters. Therefore, text fields with more than that must be truncated before calling this function.
1 2 3 4 5 6 7 8 9 10 11 | ## Not run:
conn <- connect_cdw()
demo <- mtcars
upload_table(demo, name = dplyr::in_schema("PHC_DB_DEV.REF", "DELETEME"), demo, overwrite = TRUE)
disconnect_cdw(conn)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.