Split the OP_Integer opcode into OP_Integer and OP_Int64. This allows

comments to be added to OP_Integer.  Cleanup in the optimizer.  Allow
terms of the FROM clause to be reordered automatically. (CVS 2556)

FossilOrigin-Name: e2f822ac82d0a5a59de0b63cce65d4fd6c178ff1
This commit is contained in:
drh
2005-07-21 18:23:20 +00:00
parent 7ec764a29e
commit 29dda4ae65
10 changed files with 161 additions and 197 deletions
+3 -2
View File
@@ -12,7 +12,7 @@
** This file contains C code routines that are called by the parser
** to handle INSERT statements in SQLite.
**
** $Id: insert.c,v 1.141 2005/07/08 17:13:47 drh Exp $
** $Id: insert.c,v 1.142 2005/07/21 18:23:20 drh Exp $
*/
#include "sqliteInt.h"
@@ -1096,11 +1096,12 @@ void sqlite3OpenTableAndIndices(
Vdbe *v = sqlite3GetVdbe(pParse);
assert( v!=0 );
sqlite3VdbeAddOp(v, OP_Integer, pTab->iDb, 0);
sqlite3VdbeAddOp(v, op, base, pTab->tnum);
VdbeComment((v, "# %s", pTab->zName));
sqlite3VdbeAddOp(v, op, base, pTab->tnum);
sqlite3VdbeAddOp(v, OP_SetNumColumns, base, pTab->nCol);
for(i=1, pIdx=pTab->pIndex; pIdx; pIdx=pIdx->pNext, i++){
sqlite3VdbeAddOp(v, OP_Integer, pIdx->iDb, 0);
VdbeComment((v, "# %s", pIdx->zName));
sqlite3VdbeOp3(v, op, i+base, pIdx->tnum,
(char*)&pIdx->keyInfo, P3_KEYINFO);
}