phasedarray
phasedarray

Reputation: 49

What does ":memory:" mean in the DBI::dbConnect() function?

I am learning how to use the DBI package in R and came across this sample code from the documentation

con <- DBI::dbConnect(RSQLite::SQLite(), dbname = ":memory:")

What does ":memory:" mean here? I understand that dbname = defines the name of the database, but I've never seen the format ":string:" in R before.

Upvotes: 2

Views: 69

Answers (1)

M--
M--

Reputation: 29237

From the documentation:

":memory:" is a special path that creates an in-memory database.

If you run ?DBI::dbConnect() and scroll down to the examples, you'll see this explanation as a comment for the first example code.

Upvotes: 1

Related Questions