dbConnect-SFSQLDriver-method: dbConnect

Description Usage Arguments Details Examples

Description

dbConnect for drawings that may be read by package sf

Usage

1
2
## S4 method for signature 'SFSQLDriver'
dbConnect(drv, DSN = "", readonly = TRUE, ...)

Arguments

drv

SFSQLDriver created by SFSQL()

DSN

data source name, may be a file, or folder path, database connection string, or URL

readonly

open in readonly mode (TRUE is the only option)

...

ignored

Details

The 'OGRSQL' available is documented with GDAL: https://gdal.org/user/ogr_sql_dialect.html

Examples

1
2
3
afile <- system.file("gpkg/nc.gpkg", package = "sf", mustWork = TRUE)
db <- dbConnect(SFSQL(), afile)
dbSendQuery(db, 'SELECT * FROM "nc.gpkg"')

lazysf documentation built on Nov. 14, 2020, 9:07 a.m.