Desired names for the tables on dest
; the names within the dm
remain unchanged.
Can be NULL
, a named character vector, a function or a one-sided formula.
If left NULL
(default), the names will be determined automatically depending on the temporary
argument:
temporary = TRUE
(default): unique table names based on the names of the tables in the dm
are created.
temporary = FALSE
: the table names in the dm
are used as names for the tables on dest
.
If a function or one-sided formula, table_names
is converted to a function
using rlang::as_function()
.
This function is called with the unquoted table names of the dm
object
as the only argument.
The output of this function is processed by DBI::dbQuoteIdentifier()
,
that result should be a vector of identifiers of the same length
as the original table names.
Use a variant of
table_names = ~ DBI::SQL(dbplyr::in_schema("schema_name", .x))
to specify the same schema for all tables.
Use table_names = identity
with temporary = TRUE
to avoid giving temporary tables unique names.
If a named character vector,
the names of this vector need to correspond to the table names in the dm
,
and its values are the desired names on dest
.
The value is processed by DBI::dbQuoteIdentifier()
,
that result should be a vector of identifiers of the same length
as the original table names.
Use qualified names corresponding to your database's syntax
to specify e.g. database and schema for your tables.