Skip to content

bug: WITHOUT ROWID tables are stored as ordinary rowid b-trees #727

Description

@dpsiderius

A WITHOUT ROWID table we create is stored as a rowid b-tree rather than an
index b-tree, so the oracle reports the file malformed. Confirmed identical on
origin/main and on the wave-1 branch (files compared byte-for-byte), so it is
untouched by #687 — that ticket's test correctly skips integrity_check for
this case and says why.

Why it matters: same class as #687 — a file we produce that stock SQLite
calls corrupt, a direct hit on the byte-compatibility claim.

Scope: store a WITHOUT ROWID table as an index b-tree keyed by its
declared PRIMARY KEY, PK columns first in the record. Oracle-diff:
single-column PK, composite PK, our-create/oracle-read,
oracle-create/our-read, integrity_check, and confirm no
sqlite_autoindex_* is emitted for the PK (SQLite creates none for a
WITHOUT ROWID table's own PK).

Complexity

Estimate: large
Reasoning: A storage-layout change, not a codegen fix. Kept
separate from ticket 3 for exactly that reason.

Refs: #686, #687, #715, #716

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions