mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-08 03:22:21 +03:00
First cut at optimizing single-row updates to use a one-pass algorithm. (CVS 4973)
FossilOrigin-Name: fba97f7874d723111e873d1470fc1a95e64f922d
This commit is contained in:
@@ -11,7 +11,7 @@
|
||||
*************************************************************************
|
||||
** Internal interface definitions for SQLite.
|
||||
**
|
||||
** @(#) $Id: sqliteInt.h,v 1.689 2008/04/05 18:41:43 drh Exp $
|
||||
** @(#) $Id: sqliteInt.h,v 1.690 2008/04/10 13:33:18 drh Exp $
|
||||
*/
|
||||
#ifndef _SQLITEINT_H_
|
||||
#define _SQLITEINT_H_
|
||||
@@ -1311,9 +1311,13 @@ struct WhereLevel {
|
||||
sqlite3_index_info *pIdxInfo; /* Index info for n-th source table */
|
||||
};
|
||||
|
||||
#define ORDERBY_NORMAL 0
|
||||
#define ORDERBY_MIN 1
|
||||
#define ORDERBY_MAX 2
|
||||
/*
|
||||
** Flags appropriate for the wflags parameter of sqlite3WhereBegin().
|
||||
*/
|
||||
#define WHERE_ORDERBY_NORMAL 0 /* No-op */
|
||||
#define WHERE_ORDERBY_MIN 1 /* ORDER BY processing for min() func */
|
||||
#define WHERE_ORDERBY_MAX 2 /* ORDER BY processing for max() func */
|
||||
#define WHERE_ONEPASS_DESIRED 4 /* Want to do one-pass UPDATE/DELETE */
|
||||
|
||||
/*
|
||||
** The WHERE clause processing routine has two halves. The
|
||||
@@ -1323,7 +1327,8 @@ struct WhereLevel {
|
||||
** into the second half to give some continuity.
|
||||
*/
|
||||
struct WhereInfo {
|
||||
Parse *pParse;
|
||||
Parse *pParse; /* Parsing and code generating context */
|
||||
u8 okOnePass; /* Ok to use one-pass algorithm for UPDATE or DELETE */
|
||||
SrcList *pTabList; /* List of tables in the join */
|
||||
int iTop; /* The very beginning of the WHERE loop */
|
||||
int iContinue; /* Jump here to continue with next record */
|
||||
|
||||
Reference in New Issue
Block a user