SQLite Forum

V 3.34.0
Login

V 3.34.0

(1) By anonymous on 2020-12-02 11:12:56 [link]

Using Windows 10; just downloaded v 3.34.0 & checked [the release notes](https://sqlite.org/releaselog/3_34_0.html) for changes.

<b><i>Issue 1</i></b>

<b>Session screen - 3.34.0 </b>

`SQLite version 3.34.0 2020-12-01 16:14:00
Enter ".help" for usage hints.
Connected to a transient in-memory database.
Use ".open FILENAME" to reopen on a persistent database.
sqlite> .open ./db/pubs.db
sqlite> .databases
main: D:\SQLite32\db\pubs.db r/w
sqlite>`

<b> Session screen - 3.33.0 </b>

`SQLite version 3.33.0 2020-08-14 13:23:32
Enter ".help" for usage hints.
Connected to a transient in-memory database.
Use ".open FILENAME" to reopen on a persistent database.
sqlite> .open ./db/pubs.db
sqlite> .databases
main: F:\SQLite32\db\pubs.db
sqlite>`

<b>Note r/w (I assume read/write) in the 3.34 session: Can't see this change in the release notes. Is it possible to open databases in read only mode. now?</b>

(2) By Richard Hipp (drh) on 2020-12-02 17:36:48 in reply to 1 [link]

> Can't see this change in the release notes.

Item 4f in the [change log][1].

[1]: https://www.sqlite.org/releaselog/3_34_0.html

> Is it possible to open databases in read only mode. now?

Has been for a long time.  Use ".help open" for details.  You
want the --readonly option, I think.

(3) By anonymous on 2020-12-02 18:00:38 in reply to 2 [link]

Thank you.

My session:

`SQLite version 3.34.0 2020-12-01 16:14:00
Enter ".help" for usage hints.
Connected to a transient in-memory database.
Use ".open FILENAME" to reopen on a persistent database.
sqlite> .open ./db/pubs.db --readonly
sqlite> .databases
main: D:\SQLite32\db\pubs.db r/w
sqlite>`

I'm still seeing <b>r/w</b> (expecting <b>r</b>).

(4) By anonymous on 2020-12-02 18:08:04 in reply to 3

My mistake; apologies. 

`SQLite version 3.34.0 2020-12-01 16:14:00
Enter ".help" for usage hints.
Connected to a transient in-memory database.
Use ".open FILENAME" to reopen on a persistent database.
sqlite> .open --readonly ./db/pubs.db
sqlite> .databases
main: D:\SQLite32\db\pubs.db r/o
sqlite>`

(5) By RandomCoder on 2020-12-02 18:10:42 in reply to 3 [link]

The options need to come before the file:

```
SQLite version 3.34.0 2020-12-01 16:14:00
Enter ".help" for usage hints.
Connected to a transient in-memory database.
Use ".open FILENAME" to reopen on a persistent database.
sqlite> .open dbname.db --readonly
sqlite> .databases
main: c:\test\dbname.db r/w
sqlite> .open --readonly dbname.db
sqlite> .databases
main: c:\test\dbname.db r/o
```

(6) By Keith Medcalf (kmedcalf) on 2020-12-02 18:12:00 in reply to 3 [link]

I would suggest that you read the documentation and follow it.  Your command is bassackwards.

```
>sqlite
-- Loading resources from C:\Users\KMedcalf/.sqliterc
SQLite version 3.35.0 2020-12-02 03:04:06
Enter ".help" for usage hints.
Connected to a transient in-memory database.
Use ".open FILENAME" to reopen on a persistent database.
sqlite> .help open
.open ?OPTIONS? ?FILE?   Close existing database and reopen FILE
     Options:
        --append        Use appendvfs to append database to the end of FILE
        --deserialize   Load into memory useing sqlite3_deserialize()
        --hexdb         Load the output of "dbtotxt" as an in-memory db
        --maxsize N     Maximum size for --hexdb or --deserialized database
        --new           Initialize FILE to an empty database
        --nofollow      Do not follow symbolic links
        --readonly      Open FILE readonly
        --zip           FILE is a ZIP archive
sqlite> .open --readonly cases.db
sqlite> .databases
main: D:\work\covid\cases.db r/o
sqlite>
```

(7.1) By Richard Hipp (drh) on 2020-12-02 18:22:01 edited from 7.0 in reply to 3 [link]

Deleted