From 735d75d6ce19269dc5faa00abc8f88ff30ce2f23 Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Fri, 13 Jan 2012 13:15:14 -0600 Subject: Fix inadvertent TQt string conversions This closes Bug 782 --- kexi/3rdparty/kexisql3/src/alter.c | 6 +++--- kexi/3rdparty/kexisql3/src/btree.c | 6 +++--- kexi/3rdparty/kexisql3/src/build.c | 20 ++++++++++---------- kexi/3rdparty/kexisql3/src/expr.c | 12 ++++++------ kexi/3rdparty/kexisql3/src/func.c | 2 +- kexi/3rdparty/kexisql3/src/insert.c | 10 +++++----- kexi/3rdparty/kexisql3/src/keywordhash.h | 8 ++++---- kexi/3rdparty/kexisql3/src/parse.c | 14 +++++++------- kexi/3rdparty/kexisql3/src/parse.h | 4 ++-- kexi/3rdparty/kexisql3/src/prepare.c | 2 +- kexi/3rdparty/kexisql3/src/select.c | 16 ++++++++-------- kexi/3rdparty/kexisql3/src/sqliteInt.h | 12 ++++++------ kexi/3rdparty/kexisql3/src/vacuum.c | 4 ++-- kexi/3rdparty/kexisql3/src/vdbe.c | 4 ++-- kexi/3rdparty/kexisql3/src/where.c | 12 ++++++------ 15 files changed, 66 insertions(+), 66 deletions(-) (limited to 'kexi/3rdparty/kexisql3') diff --git a/kexi/3rdparty/kexisql3/src/alter.c b/kexi/3rdparty/kexisql3/src/alter.c index 72ebd6c7..eba01e29 100644 --- a/kexi/3rdparty/kexisql3/src/alter.c +++ b/kexi/3rdparty/kexisql3/src/alter.c @@ -231,7 +231,7 @@ static void reloadTableSchema(Parse *pParse, Table *pTab, const char *zName){ #ifndef SQLITE_OMIT_TRIGGER /* Now, if the table is not stored in the temp database, reload any temp - ** triggers. Don't use IN(...) in case SQLITE_OMIT_SUBTQUERY is defined. + ** triggers. Don't use IN(...) in case SQLITE_OMIT_SUBQUERY is defined. */ if( (zWhere=whereTempTriggers(pParse, pTab)) ){ sqlite3VdbeOp3(v, OP_ParseSchema, 1, 0, zWhere, P3_DYNAMIC); @@ -407,7 +407,7 @@ void sqlite3AlterFinishAddColumn(Parse *pParse, Token *pColDef){ pDflt = 0; } - /* Check that the new column is not specified as PRIMARY KEY or UNITQUE. + /* Check that the new column is not specified as PRIMARY KEY or UNIQUE. ** If there is a NOT NULL constraint, then the default value for the ** column must not be NULL. */ @@ -416,7 +416,7 @@ void sqlite3AlterFinishAddColumn(Parse *pParse, Token *pColDef){ return; } if( pNew->pIndex ){ - sqlite3ErrorMsg(pParse, "Cannot add a UNITQUE column"); + sqlite3ErrorMsg(pParse, "Cannot add a UNIQUE column"); return; } if( pCol->notNull && !pDflt ){ diff --git a/kexi/3rdparty/kexisql3/src/btree.c b/kexi/3rdparty/kexisql3/src/btree.c index 212be42e..472d63a6 100644 --- a/kexi/3rdparty/kexisql3/src/btree.c +++ b/kexi/3rdparty/kexisql3/src/btree.c @@ -3644,7 +3644,7 @@ static void assemblePage( /* Forward reference */ static int balance(MemPage*, int); -#ifndef SQLITE_OMIT_TQUICKBALANCE +#ifndef SQLITE_OMIT_QUICKBALANCE /* ** This version of balance() handles the common special case where ** a new entry is being inserted on the extreme right-end of the @@ -3732,7 +3732,7 @@ static int balance_quick(MemPage *pPage, MemPage *pParent){ releasePage(pNew); return balance(pParent, 0); } -#endif /* SQLITE_OMIT_TQUICKBALANCE */ +#endif /* SQLITE_OMIT_QUICKBALANCE */ /* ** The ISAUTOVACUUM macro is used within balance_nonroot() to determine @@ -3822,7 +3822,7 @@ static int balance_nonroot(MemPage *pPage){ assert( pParent ); TRACE(("BALANCE: begin page %d child of %d\n", pPage->pgno, pParent->pgno)); -#ifndef SQLITE_OMIT_TQUICKBALANCE +#ifndef SQLITE_OMIT_QUICKBALANCE /* ** A special case: If a new entry has just been inserted into a ** table (that is, a btree with integer keys and all data at the leaves) diff --git a/kexi/3rdparty/kexisql3/src/build.c b/kexi/3rdparty/kexisql3/src/build.c index 67ed7975..429213da 100644 --- a/kexi/3rdparty/kexisql3/src/build.c +++ b/kexi/3rdparty/kexisql3/src/build.c @@ -746,7 +746,7 @@ void sqlite3StartTable( /* Begin generating the code that will insert the table record into ** the SQLITE_MASTER table. Note in particular that we must go ahead ** and allocate the record number for the table entry now. Before any - ** PRIMARY KEY or UNITQUE keywords are parsed. Those keywords will cause + ** PRIMARY KEY or UNIQUE keywords are parsed. Those keywords will cause ** indices to be created and the table record must come before the ** indices. Hence, the record number for the table must be allocated ** now. @@ -2011,7 +2011,7 @@ static void sqlite3RefillIndex(Parse *pParse, Index *pIndex, int memRootPage){ ** Create a new index for an SQL table. pName1.pName2 is the name of the index ** and pTblList is the name of the table that is to be indexed. Both will ** be NULL for a primary key or an index that is created to satisfy a -** UNITQUE constraint. If pTable and pIndex are NULL, use pParse->pNewTable +** UNIQUE constraint. If pTable and pIndex are NULL, use pParse->pNewTable ** as the table to be indexed. pParse->pNewTable is a table that is ** currently being constructed by a CREATE TABLE statement. ** @@ -2104,7 +2104,7 @@ void sqlite3CreateIndex( ** index, then we will continue to process this index. ** ** If pName==0 it means that we are - ** dealing with a primary key or UNITQUE constraint. We have to invent our + ** dealing with a primary key or UNIQUE constraint. We have to invent our ** own name. */ if( pName ){ @@ -2211,12 +2211,12 @@ void sqlite3CreateIndex( if( pTab==pParse->pNewTable ){ /* This routine has been called to create an automatic index as a - ** result of a PRIMARY KEY or UNITQUE clause on a column definition, or - ** a PRIMARY KEY or UNITQUE clause following the column definitions. + ** result of a PRIMARY KEY or UNIQUE clause on a column definition, or + ** a PRIMARY KEY or UNIQUE clause following the column definitions. ** i.e. one of: ** ** CREATE TABLE t(x PRIMARY KEY, y); - ** CREATE TABLE t(x, y, UNITQUE(x, y)); + ** CREATE TABLE t(x, y, UNIQUE(x, y)); ** ** Either way, check to see if the table already has such an index. If ** so, don't bother creating this one. This only applies to @@ -2285,7 +2285,7 @@ void sqlite3CreateIndex( ** we don't want to recreate it. ** ** If pTblName==0 it means this index is generated as a primary key - ** or UNITQUE constraint of a CREATE TABLE statement. Since the table + ** or UNIQUE constraint of a CREATE TABLE statement. Since the table ** has just been created, it contains no data and the index initialization ** step can be skipped. */ @@ -2309,11 +2309,11 @@ void sqlite3CreateIndex( if( pStart && pEnd ){ /* A named index with an explicit CREATE INDEX statement */ zStmt = sqlite3MPrintf("CREATE%s INDEX %.*s", - onError==OE_None ? "" : " UNITQUE", + onError==OE_None ? "" : " UNIQUE", pEnd->z - pName->z + 1, pName->z); }else{ - /* An automatic index created by a PRIMARY KEY or UNITQUE constraint */ + /* An automatic index created by a PRIMARY KEY or UNIQUE constraint */ /* zStmt = sqlite3MPrintf(""); */ zStmt = 0; } @@ -2428,7 +2428,7 @@ void sqlite3DropIndex(Parse *pParse, SrcList *pName){ goto exit_drop_index; } if( pIndex->autoIndex ){ - sqlite3ErrorMsg(pParse, "index associated with UNITQUE " + sqlite3ErrorMsg(pParse, "index associated with UNIQUE " "or PRIMARY KEY constraint cannot be dropped", 0); goto exit_drop_index; } diff --git a/kexi/3rdparty/kexisql3/src/expr.c b/kexi/3rdparty/kexisql3/src/expr.c index 8d9cfbbd..45f7fc2f 100644 --- a/kexi/3rdparty/kexisql3/src/expr.c +++ b/kexi/3rdparty/kexisql3/src/expr.c @@ -478,7 +478,7 @@ ExprList *sqlite3ExprListDup(ExprList *p){ ** called with a NULL argument. */ #if !defined(SQLITE_OMIT_VIEW) || !defined(SQLITE_OMIT_TRIGGER) \ - || !defined(SQLITE_OMIT_SUBTQUERY) + || !defined(SQLITE_OMIT_SUBQUERY) SrcList *sqlite3SrcListDup(SrcList *p){ SrcList *pNew; int i; @@ -698,7 +698,7 @@ static int exprNodeIsConstant(void *pArg, Expr *pExpr){ case TK_DOT: case TK_AGG_FUNCTION: case TK_AGG_COLUMN: -#ifndef SQLITE_OMIT_SUBTQUERY +#ifndef SQLITE_OMIT_SUBQUERY case TK_SELECT: case TK_EXISTS: #endif @@ -1190,7 +1190,7 @@ static int nameResolverStep(void *pArg, Expr *pExpr){ */ return is_agg; } -#ifndef SQLITE_OMIT_SUBTQUERY +#ifndef SQLITE_OMIT_SUBQUERY case TK_SELECT: case TK_EXISTS: #endif @@ -1273,7 +1273,7 @@ struct QueryCoder { ** of allowed values. The second form causes the SELECT to generate ** a temporary table. */ -#ifndef SQLITE_OMIT_SUBTQUERY +#ifndef SQLITE_OMIT_SUBQUERY void sqlite3CodeSubselect(Parse *pParse, Expr *pExpr){ int testAddr = 0; /* One-time test address */ Vdbe *v = sqlite3GetVdbe(pParse); @@ -1414,7 +1414,7 @@ void sqlite3CodeSubselect(Parse *pParse, Expr *pExpr){ } return; } -#endif /* SQLITE_OMIT_SUBTQUERY */ +#endif /* SQLITE_OMIT_SUBQUERY */ /* ** Generate an instruction that will put the integer describe by @@ -1649,7 +1649,7 @@ void sqlite3ExprCode(Parse *pParse, Expr *pExpr){ sqlite3VdbeOp3(v, OP_Function, constMask, nExpr, (char*)pDef, P3_FUNCDEF); break; } -#ifndef SQLITE_OMIT_SUBTQUERY +#ifndef SQLITE_OMIT_SUBQUERY case TK_EXISTS: case TK_SELECT: { sqlite3CodeSubselect(pParse, pExpr); diff --git a/kexi/3rdparty/kexisql3/src/func.c b/kexi/3rdparty/kexisql3/src/func.c index 3e50d8fb..e154c284 100644 --- a/kexi/3rdparty/kexisql3/src/func.c +++ b/kexi/3rdparty/kexisql3/src/func.c @@ -545,7 +545,7 @@ static void versionFunc( ** change. This function may disappear. Do not write code that depends ** on this function. ** -** Implementation of the TQUOTE() function. This function takes a single +** Implementation of the QUOTE() function. This function takes a single ** argument. If the argument is numeric, the return value is the same as ** the argument. If the argument is NULL, the return value is the string ** "NULL". Otherwise, the argument is enclosed in single quotes with diff --git a/kexi/3rdparty/kexisql3/src/insert.c b/kexi/3rdparty/kexisql3/src/insert.c index 7b8735a1..28d4236e 100644 --- a/kexi/3rdparty/kexisql3/src/insert.c +++ b/kexi/3rdparty/kexisql3/src/insert.c @@ -746,7 +746,7 @@ insert_cleanup: ** aIdxUsed!=0 and aIdxUsed[i]!=0. ** ** This routine also generates code to check constraints. NOT NULL, -** CHECK, and UNITQUE constraints are all checked. If a constraint fails, +** CHECK, and UNIQUE constraints are all checked. If a constraint fails, ** then the appropriate action is performed. There are five possible ** actions: ROLLBACK, ABORT, FAIL, REPLACE, and IGNORE. ** @@ -774,7 +774,7 @@ insert_cleanup: ** value for that column. If the default value ** is NULL, the action is the same as ABORT. ** -** UNITQUE REPLACE The other row that conflicts with the row +** UNIQUE REPLACE The other row that conflicts with the row ** being inserted is removed. ** ** CHECK REPLACE Illegal. The results in an exception. @@ -927,7 +927,7 @@ void sqlite3GenerateConstraintChecks( } } - /* Test all UNITQUE constraints by creating entries for each UNITQUE + /* Test all UNIQUE constraints by creating entries for each UNIQUE ** index and making sure that duplicate entries do not already exist. ** Add the new records to the indices as we go. */ @@ -951,7 +951,7 @@ void sqlite3GenerateConstraintChecks( /* Find out what action to take in case there is an indexing conflict */ onError = pIdx->onError; - if( onError==OE_None ) continue; /* pIdx is not a UNITQUE index */ + if( onError==OE_None ) continue; /* pIdx is not a UNIQUE index */ if( overrideError!=OE_Default ){ onError = overrideError; }else if( onError==OE_Default ){ @@ -1015,7 +1015,7 @@ void sqlite3GenerateConstraintChecks( break; } } -#if NULL_DISTINCT_FOR_UNITQUE +#if NULL_DISTINCT_FOR_UNIQUE sqlite3VdbeJumpHere(v, jumpInst1); #endif sqlite3VdbeJumpHere(v, jumpInst2); diff --git a/kexi/3rdparty/kexisql3/src/keywordhash.h b/kexi/3rdparty/kexisql3/src/keywordhash.h index 708440a2..9beb5fbd 100644 --- a/kexi/3rdparty/kexisql3/src/keywordhash.h +++ b/kexi/3rdparty/kexisql3/src/keywordhash.h @@ -8,8 +8,8 @@ static int keywordCode(const char *z, int n){ "CASECASTCOLLATECOLUMNCOMMITCONFLICTCONSTRAINTERSECTCREATECROSS" "CURRENT_DATECURRENT_TIMESTAMPLANDESCDETACHDISTINCTDROPRAGMATCH" "FAILIMITFROMFULLGROUPDATEIMMEDIATEINSERTINSTEADINTOFFSETISNULL" - "JOINORDEREPLACEOUTERESTRICTPRIMARYTQUERYRIGHTROLLBACKROWHENUNION" - "UNITQUEUSINGVACUUMVALUESVIEWHERE"; + "JOINORDEREPLACEOUTERESTRICTPRIMARYQUERYRIGHTROLLBACKROWHENUNION" + "UNIQUEUSINGVACUUMVALUESVIEWHERE"; static const unsigned char aHash[127] = { 91, 80, 106, 90, 0, 4, 0, 0, 113, 0, 83, 0, 0, 94, 44, 76, 92, 0, 105, 108, 96, 0, 0, 10, 0, 0, @@ -76,8 +76,8 @@ static int keywordCode(const char *z, int n){ TK_FROM, TK_JOIN_KW, TK_GROUP, TK_UPDATE, TK_IMMEDIATE, TK_INSERT, TK_INSTEAD, TK_INTO, TK_OF, TK_OFFSET, TK_SET, TK_ISNULL, TK_JOIN, TK_ORDER, TK_REPLACE, - TK_JOIN_KW, TK_RESTRICT, TK_PRIMARY, TK_TQUERY, TK_JOIN_KW, - TK_ROLLBACK, TK_ROW, TK_WHEN, TK_UNION, TK_UNITQUE, + TK_JOIN_KW, TK_RESTRICT, TK_PRIMARY, TK_QUERY, TK_JOIN_KW, + TK_ROLLBACK, TK_ROW, TK_WHEN, TK_UNION, TK_UNIQUE, TK_USING, TK_VACUUM, TK_VALUES, TK_VIEW, TK_WHERE, }; int h, i; diff --git a/kexi/3rdparty/kexisql3/src/parse.c b/kexi/3rdparty/kexisql3/src/parse.c index 7c1fe420..668f0012 100644 --- a/kexi/3rdparty/kexisql3/src/parse.c +++ b/kexi/3rdparty/kexisql3/src/parse.c @@ -682,7 +682,7 @@ static const YYCODETYPE yyFallback[] = { 0, /* CONST_FUNC => nothing */ 0, /* SEMI => nothing */ 30, /* EXPLAIN => ID */ - 30, /* TQUERY => ID */ + 30, /* QUERY => ID */ 30, /* PLAN => ID */ 30, /* BEGIN => ID */ 0, /* TRANSACTION => nothing */ @@ -770,7 +770,7 @@ static const YYCODETYPE yyFallback[] = { 0, /* DEFAULT => nothing */ 0, /* NULL => nothing */ 0, /* PRIMARY => nothing */ - 0, /* UNITQUE => nothing */ + 0, /* UNIQUE => nothing */ 0, /* CHECK => nothing */ 0, /* REFERENCES => nothing */ 0, /* COLLATE => nothing */ @@ -910,7 +910,7 @@ static const char *const yyTokenName[] = { "STAR", "SLASH", "REM", "CONCAT", "UMINUS", "UPLUS", "BITNOT", "STRING", "JOIN_KW", "CONSTRAINT", "DEFAULT", "NULL", - "PRIMARY", "UNITQUE", "CHECK", "REFERENCES", + "PRIMARY", "UNIQUE", "CHECK", "REFERENCES", "COLLATE", "AUTOINCR", "ON", "DELETE", "UPDATE", "INSERT", "SET", "DEFERRABLE", "FOREIGN", "DROP", "UNION", "ALL", @@ -962,7 +962,7 @@ static const char *const yyRuleName[] = { /* 5 */ "ecmd ::= explain cmdx SEMI", /* 6 */ "explain ::=", /* 7 */ "explain ::= EXPLAIN", - /* 8 */ "explain ::= EXPLAIN TQUERY PLAN", + /* 8 */ "explain ::= EXPLAIN QUERY PLAN", /* 9 */ "cmd ::= BEGIN transtype trans_opt", /* 10 */ "trans_opt ::=", /* 11 */ "trans_opt ::= TRANSACTION", @@ -1011,7 +1011,7 @@ static const char *const yyRuleName[] = { /* 54 */ "ccons ::= NULL onconf", /* 55 */ "ccons ::= NOT NULL onconf", /* 56 */ "ccons ::= PRIMARY KEY sortorder onconf autoinc", - /* 57 */ "ccons ::= UNITQUE onconf", + /* 57 */ "ccons ::= UNIQUE onconf", /* 58 */ "ccons ::= CHECK LP expr RP onconf", /* 59 */ "ccons ::= REFERENCES nm idxlist_opt refargs", /* 60 */ "ccons ::= defer_subclause", @@ -1040,7 +1040,7 @@ static const char *const yyRuleName[] = { /* 83 */ "conslist ::= tcons", /* 84 */ "tcons ::= CONSTRAINT nm", /* 85 */ "tcons ::= PRIMARY KEY LP idxlist autoinc RP onconf", - /* 86 */ "tcons ::= UNITQUE LP idxlist RP onconf", + /* 86 */ "tcons ::= UNIQUE LP idxlist RP onconf", /* 87 */ "tcons ::= CHECK expr onconf", /* 88 */ "tcons ::= FOREIGN KEY LP idxlist RP REFERENCES nm idxlist_opt refargs defer_subclause_opt", /* 89 */ "defer_subclause_opt ::=", @@ -1199,7 +1199,7 @@ static const char *const yyRuleName[] = { /* 242 */ "expritem ::= expr", /* 243 */ "expritem ::=", /* 244 */ "cmd ::= CREATE uniqueflag INDEX nm dbnm ON nm LP idxlist RP onconf", - /* 245 */ "uniqueflag ::= UNITQUE", + /* 245 */ "uniqueflag ::= UNIQUE", /* 246 */ "uniqueflag ::=", /* 247 */ "idxlist_opt ::=", /* 248 */ "idxlist_opt ::= LP idxlist RP", diff --git a/kexi/3rdparty/kexisql3/src/parse.h b/kexi/3rdparty/kexisql3/src/parse.h index b96836ce..fcedda58 100644 --- a/kexi/3rdparty/kexisql3/src/parse.h +++ b/kexi/3rdparty/kexisql3/src/parse.h @@ -10,7 +10,7 @@ #define TK_CONST_FUNC 10 #define TK_SEMI 11 #define TK_EXPLAIN 12 -#define TK_TQUERY 13 +#define TK_QUERY 13 #define TK_PLAN 14 #define TK_BEGIN 15 #define TK_TRANSACTION 16 @@ -98,7 +98,7 @@ #define TK_DEFAULT 98 #define TK_NULL 99 #define TK_PRIMARY 100 -#define TK_UNITQUE 101 +#define TK_UNIQUE 101 #define TK_CHECK 102 #define TK_REFERENCES 103 #define TK_COLLATE 104 diff --git a/kexi/3rdparty/kexisql3/src/prepare.c b/kexi/3rdparty/kexisql3/src/prepare.c index a0c7be87..b3222a82 100644 --- a/kexi/3rdparty/kexisql3/src/prepare.c +++ b/kexi/3rdparty/kexisql3/src/prepare.c @@ -77,7 +77,7 @@ int sqlite3InitCallback(void *pInit, int argc, char **argv, char **azColName){ } }else{ /* If the SQL column is blank it means this is an index that - ** was created to be the PRIMARY KEY or to fulfill a UNITQUE + ** was created to be the PRIMARY KEY or to fulfill a UNIQUE ** constraint for a CREATE TABLE. The index should have already ** been created when we processed the CREATE TABLE. All we have ** to do here is record the root page number for that index. diff --git a/kexi/3rdparty/kexisql3/src/select.c b/kexi/3rdparty/kexisql3/src/select.c index 7cb7b176..86b22c38 100644 --- a/kexi/3rdparty/kexisql3/src/select.c +++ b/kexi/3rdparty/kexisql3/src/select.c @@ -518,7 +518,7 @@ static int selectInnerLoop( break; } -#ifndef SQLITE_OMIT_SUBTQUERY +#ifndef SQLITE_OMIT_SUBQUERY /* If we are creating a set for an "expr IN (SELECT ...)" construct, ** then there should be a single item on the stack. Write this ** item into the set table with bogus data. @@ -562,7 +562,7 @@ static int selectInnerLoop( } break; } -#endif /* #ifndef SQLITE_OMIT_SUBTQUERY */ +#endif /* #ifndef SQLITE_OMIT_SUBQUERY */ /* Send the data to the callback function or to a subroutine. In the ** case of a subroutine, the subroutine itself is responsible for @@ -671,7 +671,7 @@ static void generateSortTail( sqlite3VdbeAddOp(v, OP_Insert, iParm, 0); break; } -#ifndef SQLITE_OMIT_SUBTQUERY +#ifndef SQLITE_OMIT_SUBQUERY case SRT_Set: { assert( nColumn==1 ); sqlite3VdbeAddOp(v, OP_NotNull, -1, sqlite3VdbeCurrentAddr(v)+3); @@ -773,7 +773,7 @@ static const char *columnType(NameContext *pNC, Expr *pExpr){ } break; } -#ifndef SQLITE_OMIT_SUBTQUERY +#ifndef SQLITE_OMIT_SUBQUERY case TK_SELECT: { NameContext sNC; Select *pS = pExpr->pSelect; @@ -1058,7 +1058,7 @@ static int prepSelectStmt(Parse *pParse, Select *p){ return 0; } if( pFrom->zName==0 ){ -#ifndef SQLITE_OMIT_SUBTQUERY +#ifndef SQLITE_OMIT_SUBQUERY /* A sub-query in the FROM clause of a SELECT */ assert( pFrom->pSelect!=0 ); if( pFrom->zAlias==0 ){ @@ -2664,7 +2664,7 @@ int sqlite3Select( ** only a single column may be output. */ assert( eDest!=SRT_Exists || pEList->nExpr==1 ); -#ifndef SQLITE_OMIT_SUBTQUERY +#ifndef SQLITE_OMIT_SUBQUERY if( (eDest==SRT_Mem || eDest==SRT_Set) && pEList->nExpr>1 ){ sqlite3ErrorMsg(pParse, "only a single result allowed for " "a SELECT that is part of an expression"); @@ -2692,7 +2692,7 @@ int sqlite3Select( /* Generate code for all sub-queries in the FROM clause */ -#if !defined(SQLITE_OMIT_SUBTQUERY) || !defined(SQLITE_OMIT_VIEW) +#if !defined(SQLITE_OMIT_SUBQUERY) || !defined(SQLITE_OMIT_VIEW) for(i=0; inSrc; i++){ const char *zSavedAuthContext = 0; int needRestoreContext; @@ -3098,7 +3098,7 @@ int sqlite3Select( generateSortTail(pParse, p, v, pEList->nExpr, eDest, iParm); } -#ifndef SQLITE_OMIT_SUBTQUERY +#ifndef SQLITE_OMIT_SUBQUERY /* If this was a subquery, we have now converted the subquery into a ** temporary table. So delete the subquery structure from the parent ** to prevent this subquery from being evaluated again and to force the diff --git a/kexi/3rdparty/kexisql3/src/sqliteInt.h b/kexi/3rdparty/kexisql3/src/sqliteInt.h index 153b537b..796653e7 100644 --- a/kexi/3rdparty/kexisql3/src/sqliteInt.h +++ b/kexi/3rdparty/kexisql3/src/sqliteInt.h @@ -104,16 +104,16 @@ /* ** If the following macro is set to 1, then NULL values are considered ** distinct when determining whether or not two entries are the same -** in a UNITQUE index. This is the way PostgreSQL, Oracle, DB2, MySQL, +** in a UNIQUE index. This is the way PostgreSQL, Oracle, DB2, MySQL, ** OCELOT, and Firebird all work. The SQL92 spec explicitly says this ** is the way things are suppose to work. ** ** If the following macro is set to 0, the NULLs are indistinct for -** a UNITQUE index. In this mode, you can only have a single NULL entry -** for a column declared UNITQUE. This is the way Informix and SQL Server +** a UNIQUE index. In this mode, you can only have a single NULL entry +** for a column declared UNIQUE. This is the way Informix and SQL Server ** work. */ -#define NULL_DISTINCT_FOR_UNITQUE 1 +#define NULL_DISTINCT_FOR_UNIQUE 1 /* ** The maximum number of attached databases. This must be at least 2 @@ -700,7 +700,7 @@ struct FKey { ** occurs. IGNORE means that the particular row that caused the constraint ** error is not inserted or updated. Processing continues and no error ** is returned. REPLACE means that preexisting database rows that caused -** a UNITQUE constraint violation are removed so that the new insert or +** a UNIQUE constraint violation are removed so that the new insert or ** update can proceed. Processing continues and no error is reported. ** ** RESTRICT, SETNULL, and CASCADE actions apply only to foreign keys. @@ -779,7 +779,7 @@ struct Index { Table *pTable; /* The SQL table being indexed */ int tnum; /* Page containing root of this index in database file */ u8 onError; /* OE_Abort, OE_Ignore, OE_Replace, or OE_None */ - u8 autoIndex; /* True if is automatically created (ex: by UNITQUE) */ + u8 autoIndex; /* True if is automatically created (ex: by UNIQUE) */ u8 iDb; /* Index in sqlite.aDb[] of where this index is stored */ char *zColAff; /* String defining the affinity of each column */ Index *pNext; /* The next index associated with the same table */ diff --git a/kexi/3rdparty/kexisql3/src/vacuum.c b/kexi/3rdparty/kexisql3/src/vacuum.c index 8f22c7f8..6f544a6b 100644 --- a/kexi/3rdparty/kexisql3/src/vacuum.c +++ b/kexi/3rdparty/kexisql3/src/vacuum.c @@ -212,8 +212,8 @@ int sqlite3RunVacuum(char **pzErrMsg, sqlite3 *db){ " FROM sqlite_master WHERE sql LIKE 'CREATE INDEX %' ", 0); if( rc!=SQLITE_OK ) goto end_of_vacuum; rc = execExecSql(db, - "SELECT 'CREATE UNITQUE INDEX vacuum_db.' || substr(sql,21,100000000) " - " FROM sqlite_master WHERE sql LIKE 'CREATE UNITQUE INDEX %'", 0); + "SELECT 'CREATE UNIQUE INDEX vacuum_db.' || substr(sql,21,100000000) " + " FROM sqlite_master WHERE sql LIKE 'CREATE UNIQUE INDEX %'", 0); if( rc!=SQLITE_OK ) goto end_of_vacuum; rc = execExecSql(db, "SELECT 'CREATE VIEW vacuum_db.' || substr(sql,13,100000000) " diff --git a/kexi/3rdparty/kexisql3/src/vdbe.c b/kexi/3rdparty/kexisql3/src/vdbe.c index 8ff95946..e70c0d2d 100644 --- a/kexi/3rdparty/kexisql3/src/vdbe.c +++ b/kexi/3rdparty/kexisql3/src/vdbe.c @@ -1676,7 +1676,7 @@ case OP_BitNot: { /* same as TK_BITNOT, no-push */ */ /* ** The magic Explain opcode are only inserted when explain==2 (which -** is to say when the EXPLAIN TQUERY PLAN syntax is used.) +** is to say when the EXPLAIN QUERY PLAN syntax is used.) ** This opcode records information from the optimizer. It is the ** the same as a no-op. This opcodesnever appears in a real VM program. */ @@ -2956,7 +2956,7 @@ case OP_IsUnique: { /* no-push */ } /* The final varint of the key is different from R. Push it onto - ** the stack. (The record number of an entry that violates a UNITQUE + ** the stack. (The record number of an entry that violates a UNIQUE ** constraint.) */ pTos++; diff --git a/kexi/3rdparty/kexisql3/src/where.c b/kexi/3rdparty/kexisql3/src/where.c index c0457ffc..a4b0c5fc 100644 --- a/kexi/3rdparty/kexisql3/src/where.c +++ b/kexi/3rdparty/kexisql3/src/where.c @@ -170,7 +170,7 @@ struct ExprMaskSet { #define WHERE_IDX_ONLY 0x0800 /* Use index only - omit table */ #define WHERE_ORDERBY 0x1000 /* Output will appear in correct order */ #define WHERE_REVERSE 0x2000 /* Scan in reverse order */ -#define WHERE_UNITQUE 0x4000 /* Selects no more than one row */ +#define WHERE_UNIQUE 0x4000 /* Selects no more than one row */ /* ** Initialize a preallocated WhereClause structure. @@ -747,7 +747,7 @@ or_not_possible: ** clause and the match can still be a success. ** ** All terms of the ORDER BY that match against the index must be either -** ASC or DESC. (Terms of the ORDER BY clause past the end of a UNITQUE +** ASC or DESC. (Terms of the ORDER BY clause past the end of a UNIQUE ** index do not need to satisfy this constraint.) The *pbRev value is ** set to 1 if the ORDER BY clause is all DESC and it is set to 0 if ** the ORDER BY clause is all ASC. @@ -915,7 +915,7 @@ static double bestIndex( if( pTerm->operator & WO_EQ ){ /* Rowid== is always the best pick. Look no further. Because only ** a single row is generated, output is always in sorted order */ - *pFlags = WHERE_ROWID_EQ | WHERE_UNITQUE; + *pFlags = WHERE_ROWID_EQ | WHERE_UNIQUE; *pnEq = 1; TRACE(("... best is rowid\n")); return 0.0; @@ -1007,7 +1007,7 @@ static double bestIndex( nEq = i; if( pProbe->onError!=OE_None && (flags & WHERE_COLUMN_IN)==0 && nEq==pProbe->nColumn ){ - flags |= WHERE_UNITQUE; + flags |= WHERE_UNIQUE; } TRACE(("...... nEq=%d inMult=%.9g cost=%.9g\n", nEq, inMultiplier, cost)); @@ -1169,7 +1169,7 @@ static void codeEqualityTerm( if( pX->op!=TK_IN ){ assert( pX->op==TK_EQ ); sqlite3ExprCode(pParse, pX->pRight); -#ifndef SQLITE_OMIT_SUBTQUERY +#ifndef SQLITE_OMIT_SUBQUERY }else{ int iTab; int *aIn; @@ -1514,7 +1514,7 @@ WhereInfo *sqlite3WhereBegin( /* If the total query only selects a single row, then the ORDER BY ** clause is irrelevant. */ - if( (andFlags & WHERE_UNITQUE)!=0 && ppOrderBy ){ + if( (andFlags & WHERE_UNIQUE)!=0 && ppOrderBy ){ *ppOrderBy = 0; } -- cgit v1.2.1