rws_connect: Opens SQLite Database Connection

View source: R/connection.R

rws_connectR Documentation

Opens SQLite Database Connection

Description

Opens a SQLiteConnection to a SQLite database with foreign key constraints enabled.

Usage

rws_connect(dbname = ":memory:", exists = NA)

Arguments

dbname

The path to the database file. SQLite keeps each database instance in one single file. The name of the database is the file name, thus database names should be legal file names in the running platform. There are two exceptions:

  • "" will create a temporary on-disk database. The file will be deleted when the connection is closed.

  • ":memory:" or "file::memory:" will create a temporary in-memory database.

exists

A flag specifying whether the table(s) must already exist.

Value

A SQLiteConnection to a SQLite database with foreign key constraints enabled.

See Also

rws_disconnect()

Examples

conn <- rws_connect()
print(conn)
rws_disconnect(conn)

poissonconsulting/dbWriteSQLite documentation built on Oct. 20, 2022, 11:06 p.m.