View source: R/dbplyr-simulate.R
| simulate_trino | R Documentation |
Returns an object that carries the TrinoConnection class without holding a
session, so sql_dialect.TrinoConnection() and, through it,
sql_translation.sql_dialect_trino() dispatch as they would on a live
connection. Useful for inspecting the SQL a dplyr pipeline produces, and
used by this package's own translation tests, which then need no coordinator
at all. Anything that reaches the database, such as collect(), still fails.
simulate_trino()
A simulated dbplyr connection of class TrinoConnection.
if (requireNamespace("dbplyr", quietly = TRUE) &&
utils::packageVersion("dbplyr") >= "2.6.0") {
con <- simulate_trino()
dbplyr::translate_sql(as.numeric(x), con = con)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.