I know that I can open multiple connections to an In-Memory sqlite database using
SQLITE_OPEN_URI | SQLITE_OPEN_CREATE | SQLITE_OPEN_READWRITE
SQLITE_OPEN_READONLY | SQLITE_OPEN_URI
SQLITE_OPEN_READONLY flag affects how the database accesses any files and handles transactions.
In shared-cache mode, multiple connections appear as a single connection in the interface to the file system. Therefore, they share the file access/transaction settings.
To prevent a connection from starting any write transactions, use PRAGMA query_only.