Build the admin table as it was at a point in the past
cdr_reconstruct_past_tbl.Rd
Build the admin table as it was at a point in the past
Arguments
- as_of
datetime object in the past, e.g. lubridate::now()-lubridate::weeks(4)
- conn_pool
pool or DBI connection
- db_tbl_name
primary table name
- chg_log_suffix
your table name extension specifying the corresponding change-log table, e.g. '_deltas'
- key_field
column in the primary table that acts as the unique row identifier
- ...
other connection parameters like
schema = public
Examples
if (FALSE) {
conn_pool <- pool::dbPool(
DBI::dbConnect( drv = RPostgreSQL::PostgreSQL(),
dbname = "test",
host = "localhost",
port = "5432",
user = Sys.getenv('postgres_username'),
password = Sys.getenv('postgres_password'))
)
cdr_reconstruct_past_tbl(conn_pool = conn_pool, db_tbl_name = 'mtcars', schema = "test")
cdr_reconstruct_past_tbl(conn_pool = conn_pool, db_tbl_name = 'mtcars', schema = "test")
pool::poolClose(conn_pool)
}