Description Usage Arguments Details Value Examples
Connect to the orderly databases. These should be treated as as read-only.
1 |
type |
The type of connection to make ( |
root |
The path to an orderly root directory, or |
locate |
Logical, indicating if the configuration should be
searched for. If |
validate |
Logical, indicating if the database schema should
be validated on open (currently only applicable with |
instance |
Used only by |
Orderly has several databases:
source
: All of the databases named in the database
section
of the orderly_config.yml
destination
: The orderly index database (typically a SQLite
database stored at the orderly root)
csv
: The cache of database query results, in csv format
rds
: The cache of database query results, in rds format
A database connection, or list of connections in the case
of source
.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 | # Create an orderly that has a single commited report:
path <- orderly::orderly_example("minimal")
id <- orderly::orderly_run("example", root = path)
orderly::orderly_commit(id, root = path)
# The source database holds the data that might be accessible via
# the 'data' entry in orderly.yml:
db <- orderly::orderly_db("source", root = path)
# This is a list, with one connection per database listed in the
# orderly_config.yml (an empty list if none are specified):
db
DBI::dbListTables(db$source)
head(DBI::dbReadTable(db$source, "data"))
DBI::dbDisconnect(db$source)
# The destination database holds information about the archived
# reports:
db <- orderly::orderly_db("destination", root = path)
DBI::dbListTables(db)
# These tables are documented online:
# https://vimc.github.io/orderly/schema
DBI::dbReadTable(db, "report_version")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.