SQLite User Forum

.clone command should suppress one error
Login

.clone command should suppress one error

(1) By anonymous on 2023-01-16 01:32:54 [source]

Observed

SQLite 3.40.1, Linux/amd64:

$ sqlite3
Connected to a transient in-memory database.
sqlite> create table t (id INTEGER PRIMARY KEY AUTOINCREMENT);
sqlite> .clone newdb
t... done
sqlite_sequence... Error: object name reserved for internal use: sqlite_sequence
SQL: [CREATE TABLE sqlite_sequence(name,seq)]
done

Expected

Silently skip the sqlite_sequence table, perhaps.

(2) By Larry Brasfield (larrybr) on 2023-01-16 21:57:56 in reply to 1 [link] [source]

Thanks for reporting this. Fixed here. The sequence table is not exactly skipped, in consideration of its possibly valuable content. But its needless creation is skipped. This is a reasonable-effort kind of thing, without the complexity that could have gone into it.1


  1. ^ If the schema table is corrupt enough to not get replicated by the code present now, there are likely much worse problems than a not-yet-populated sqlite_sequence table.