Description Usage Arguments Details Value Examples
View source: R/prorepparcodes.R
Add product reporter and partner to a tbl object
1 2 3 | addproreppar2tbl(RMariaDBcon, maintbl)
addunit2tbl(RMariaDBcon, maintbl, tableunit = "vld_comext_unit")
|
RMariaDBcon |
database connection object created by RMySQL |
maintbl |
tbl containing trade data, with productcode, reportercode and partnercode |
addunit2tbl joints all unit codes, then removes those which are out dated
a tbl object left joined to the product, reporter and partner tables.
1 2 3 4 5 6 7 8 9 10 | ## Not run:
con <- RMariaDB::dbConnect(RMariaDB::MariaDB(), dbname = "test")
monthly <- tbl(con, "raw_comext_monthly_201707")
monthly %>%
filter(productcode == 44) %>%
addproreppar2tbl(con, .) %>%
collect()
RMariaDB::dbDisconnect(con)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.