Repository navigation
Commit 60b4b76
committed
Patch Doltlite to keep composite-PK tables as rowid tables
Doltlite silently sets TF_WithoutRowid on every table declared with
a primary key, so `SELECT rowid FROM t` fails with "no such column:
rowid". The mysql-on-sqlite driver uses `ORDER BY ROWID` as a stable
tie-break when reading its internal information_schema tables, so
dropping rowid breaks info-schema lookups across the board.
Patch by sed: replace the single `tabOpts |= TF_WithoutRowid;` line
in src/build.c with a no-op, leaving table creation otherwise
untouched. Verified with a PHP one-liner that a composite-PK table
still returns a rowid.1 parent af14bb3 commit 60b4b76
1 file changed
Lines changed: 33 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
34 | 53 | | |
35 | 54 | | |
36 | 55 | | |
| |||
74 | 93 | | |
75 | 94 | | |
76 | 95 | | |
77 | | - | |
| 96 | + | |
78 | 97 | | |
79 | 98 | | |
80 | 99 | | |
| |||
84 | 103 | | |
85 | 104 | | |
86 | 105 | | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
87 | 119 | | |
88 | 120 | | |
89 | 121 | | |
| |||
0 commit comments