1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-08-08 14:02:16 +03:00

Fix an incorrect assert in the ANALYZE logic for STAT4 on WITHOUT ROWID

tables.

FossilOrigin-Name: ad741976c8c29bcc94f9ea9ed7deb580bb00c8a81d1a7fba1a4e03849728433d
This commit is contained in:
drh
2017-03-21 18:56:52 +00:00
parent 119fc11eb0
commit 49297c86d2
3 changed files with 9 additions and 9 deletions

View File

@@ -1204,7 +1204,7 @@ static void analyzeOneTable(
regKey = sqlite3GetTempRange(pParse, pPk->nKeyCol);
for(j=0; j<pPk->nKeyCol; j++){
k = sqlite3ColumnOfIndex(pIdx, pPk->aiColumn[j]);
assert( k>=0 && k<pTab->nCol );
assert( k>=0 && k<pIdx->nColumn );
sqlite3VdbeAddOp3(v, OP_Column, iIdxCur, k, regKey+j);
VdbeComment((v, "%s", pTab->aCol[pPk->aiColumn[j]].zName));
}