View source: R/compute_with_parallelism.R
compute_with_parallelism | R Documentation |
Compute (a-la dbplyr) a lazy query with specified degree of parallelism. Adds a parallel hint to all SELECT statements: SELECT /* +PARALLEL(N) */...
The hint is usually taken into account, but as it is only a hint, the database optimizer ultimately makes a final decision as to which degree of parallelism to use, if any. This is based on things like the query itself and the amount of concurrent use.
If hints are already present in any sub-queries, e.g. included manually using dbplyr::sql()
, this function will overwrite them.
compute_with_parallelism(
lazy_tbl,
create_table_name,
n,
overwrite = F,
compress = "high",
materialize = F
)
lazy_tbl |
name of the dbplyr lazy table |
create_table_name |
name of user created table in SQL database |
n |
the degree of parallelism to enforce |
overwrite |
if |
compress |
Compression setting for the table: |
materialize |
if |
## Not run:
compute_with_parallelism(table_db, "INT646_TABLE_DB", 32)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.