
SQL to attach a CDM file (and its vocabulary) read-only on every connection (FR-D4)
Source:R/hades_bridge.R
readonly_attach_sql.RdSite files often expose concept and the other vocabulary tables as views into a catalog named central_vocab.
Those views only resolve when the vocabulary file is attached under exactly that name. HADES opens several
connections per run and DatabaseConnector cannot ATTACH on connect, so run these statements on each new connection
(see cohorts/run_plp_readonly_example.R). Nothing is written to either file.
Usage
readonly_attach_sql(
cdm_db,
vocab_db = NULL,
cdm_alias = "cdm",
vocab_alias = "central_vocab"
)