1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-12 13:01:09 +03:00

Change the sqlite3OpenTable() utility to open the PRIMARY KEY index when

reading a WITHOUT ROWID table.

FossilOrigin-Name: 247f389930aededaa54ecb792748aa8d0ad6d57b
This commit is contained in:
drh
2013-10-23 23:37:02 +00:00
parent 4415628a4a
commit dd9930ef20
5 changed files with 27 additions and 23 deletions

View File

@@ -5955,7 +5955,7 @@ WhereInfo *sqlite3WhereBegin(
sqlite3OpenTable(pParse, pTabItem->iCursor, iDb, pTab, op);
testcase( !pWInfo->okOnePass && pTab->nCol==BMS-1 );
testcase( !pWInfo->okOnePass && pTab->nCol==BMS );
if( !pWInfo->okOnePass && pTab->nCol<BMS ){
if( !pWInfo->okOnePass && pTab->nCol<BMS && HasRowid(pTab) ){
Bitmask b = pTabItem->colUsed;
int n = 0;
for(; b; b=b>>1, n++){}