@@ -120,7 +120,7 @@ SQLITE_API LPWSTR sqlite3_win32_utf8_to_unicode(const char*);
120120/*** Begin of #include "sqlite3patched.c" ***/
121121/******************************************************************************
122122** This file is an amalgamation of many separate C source files from SQLite
123- ** version 3.50.3 . By combining all the individual C code files into this
123+ ** version 3.50.4 . By combining all the individual C code files into this
124124** single large file, the entire code can be compiled as a single translation
125125** unit. This allows many compilers to do optimizations that would not be
126126** possible if the files were compiled separately. Performance improvements
@@ -138,7 +138,7 @@ SQLITE_API LPWSTR sqlite3_win32_utf8_to_unicode(const char*);
138138** separate file. This file contains only code for the core SQLite library.
139139**
140140** The content in this amalgamation comes from Fossil check-in
141- ** 3ce993b8657d6d9deda380a93cdd6404a8c8 with changes in files:
141+ ** 4d8adfb30e03f9cf27f800a2c1ba3c48fb4c with changes in files:
142142**
143143**
144144*/
@@ -585,9 +585,9 @@ extern "C" {
585585** [sqlite3_libversion_number()], [sqlite3_sourceid()],
586586** [sqlite_version()] and [sqlite_source_id()].
587587*/
588- #define SQLITE_VERSION "3.50.3 "
589- #define SQLITE_VERSION_NUMBER 3050003
590- #define SQLITE_SOURCE_ID "2025-07-17 13:25:10 3ce993b8657d6d9deda380a93cdd6404a8c8ba1b185b2bc423703e41ae5f2543 "
588+ #define SQLITE_VERSION "3.50.4 "
589+ #define SQLITE_VERSION_NUMBER 3050004
590+ #define SQLITE_SOURCE_ID "2025-07-30 19:33:53 4d8adfb30e03f9cf27f800a2c1ba3c48fb4ca1b08b0f5ed59a4d5ecbf45e20a3 "
591591
592592/*
593593** CAPI3REF: Run-Time Library Version Numbers
@@ -19574,6 +19574,7 @@ struct Expr {
1957419574 Table *pTab; /* TK_COLUMN: Table containing column. Can be NULL
1957519575 ** for a column of an index on an expression */
1957619576 Window *pWin; /* EP_WinFunc: Window/Filter defn for a function */
19577+ int nReg; /* TK_NULLS: Number of registers to NULL out */
1957719578 struct { /* TK_IN, TK_SELECT, and TK_EXISTS */
1957819579 int iAddr; /* Subroutine entry address */
1957919580 int regReturn; /* Register used to hold return address */
@@ -21608,6 +21609,7 @@ SQLITE_PRIVATE void sqlite3ExprCodeGeneratedColumn(Parse*, Table*, Column*, int)
2160821609SQLITE_PRIVATE void sqlite3ExprCodeCopy(Parse*, Expr*, int);
2160921610SQLITE_PRIVATE void sqlite3ExprCodeFactorable(Parse*, Expr*, int);
2161021611SQLITE_PRIVATE int sqlite3ExprCodeRunJustOnce(Parse*, Expr*, int);
21612+ SQLITE_PRIVATE void sqlite3ExprNullRegisterRange(Parse*, int, int);
2161121613SQLITE_PRIVATE int sqlite3ExprCodeTemp(Parse*, Expr*, int*);
2161221614SQLITE_PRIVATE int sqlite3ExprCodeTarget(Parse*, Expr*, int);
2161321615SQLITE_PRIVATE int sqlite3ExprCodeExprList(Parse*, ExprList*, int, int, u8);
@@ -115392,6 +115394,12 @@ SQLITE_PRIVATE int sqlite3ExprCodeTarget(Parse *pParse, Expr *pExpr, int target)
115392115394 sqlite3VdbeLoadString(v, target, pExpr->u.zToken);
115393115395 return target;
115394115396 }
115397+ case TK_NULLS: {
115398+ /* Set a range of registers to NULL. pExpr->y.nReg registers starting
115399+ ** with target */
115400+ sqlite3VdbeAddOp3(v, OP_Null, 0, target, target + pExpr->y.nReg - 1);
115401+ return target;
115402+ }
115395115403 default: {
115396115404 /* Make NULL the default case so that if a bug causes an illegal
115397115405 ** Expr node to be passed into this function, it will be handled
@@ -116076,6 +116084,25 @@ SQLITE_PRIVATE int sqlite3ExprCodeRunJustOnce(
116076116084 return regDest;
116077116085}
116078116086
116087+ /*
116088+ ** Make arrangements to invoke OP_Null on a range of registers
116089+ ** during initialization.
116090+ */
116091+ SQLITE_PRIVATE SQLITE_NOINLINE void sqlite3ExprNullRegisterRange(
116092+ Parse *pParse, /* Parsing context */
116093+ int iReg, /* First register to set to NULL */
116094+ int nReg /* Number of sequential registers to NULL out */
116095+ ){
116096+ u8 okConstFactor = pParse->okConstFactor;
116097+ Expr t;
116098+ memset(&t, 0, sizeof(t));
116099+ t.op = TK_NULLS;
116100+ t.y.nReg = nReg;
116101+ pParse->okConstFactor = 1;
116102+ sqlite3ExprCodeRunJustOnce(pParse, &t, iReg);
116103+ pParse->okConstFactor = okConstFactor;
116104+ }
116105+
116079116106/*
116080116107** Generate code to evaluate an expression and store the results
116081116108** into a register. Return the register number where the results
@@ -153331,6 +153358,7 @@ SQLITE_PRIVATE int sqlite3Select(
153331153358 sqlite3VdbeAddOp2(v, OP_Integer, 0, iAbortFlag);
153332153359 VdbeComment((v, "clear abort flag"));
153333153360 sqlite3VdbeAddOp3(v, OP_Null, 0, iAMem, iAMem+pGroupBy->nExpr-1);
153361+ sqlite3ExprNullRegisterRange(pParse, iAMem, pGroupBy->nExpr);
153334153362
153335153363 /* Begin a loop that will extract all source rows in GROUP BY order.
153336153364 ** This might involve two separate loops with an OP_Sort in between, or
@@ -168635,6 +168663,7 @@ static int whereLoopAddBtree(
168635168663 pNew->u.btree.nEq = 0;
168636168664 pNew->u.btree.nBtm = 0;
168637168665 pNew->u.btree.nTop = 0;
168666+ pNew->u.btree.nDistinctCol = 0;
168638168667 pNew->nSkip = 0;
168639168668 pNew->nLTerm = 0;
168640168669 pNew->iSortIdx = 0;
@@ -169703,8 +169732,6 @@ static i8 wherePathSatisfiesOrderBy(
169703169732 obSat = obDone;
169704169733 }
169705169734 break;
169706- }else if( wctrlFlags & WHERE_DISTINCTBY ){
169707- pLoop->u.btree.nDistinctCol = 0;
169708169735 }
169709169736 iCur = pWInfo->pTabList->a[pLoop->iTab].iCursor;
169710169737
@@ -257458,7 +257485,7 @@ static void fts5SourceIdFunc(
257458257485){
257459257486 assert( nArg==0 );
257460257487 UNUSED_PARAM2(nArg, apUnused);
257461- sqlite3_result_text(pCtx, "fts5: 2025-07-17 13:25:10 3ce993b8657d6d9deda380a93cdd6404a8c8ba1b185b2bc423703e41ae5f2543 ", -1, SQLITE_TRANSIENT);
257488+ sqlite3_result_text(pCtx, "fts5: 2025-07-30 19:33:53 4d8adfb30e03f9cf27f800a2c1ba3c48fb4ca1b08b0f5ed59a4d5ecbf45e20a3 ", -1, SQLITE_TRANSIENT);
257462257489}
257463257490
257464257491/*
@@ -263297,9 +263324,9 @@ SQLITE_API const char *sqlite3_sourceid(void){ return SQLITE_SOURCE_ID; }
263297263324
263298263325#define SQLITE3MC_VERSION_MAJOR 2
263299263326#define SQLITE3MC_VERSION_MINOR 2
263300- #define SQLITE3MC_VERSION_RELEASE 3
263327+ #define SQLITE3MC_VERSION_RELEASE 4
263301263328#define SQLITE3MC_VERSION_SUBRELEASE 0
263302- #define SQLITE3MC_VERSION_STRING "SQLite3 Multiple Ciphers 2.2.3 "
263329+ #define SQLITE3MC_VERSION_STRING "SQLite3 Multiple Ciphers 2.2.4 "
263303263330
263304263331#endif /* SQLITE3MC_VERSION_H_ */
263305263332/*** End of #include "sqlite3mc_version.h" ***/
@@ -263458,9 +263485,9 @@ extern "C" {
263458263485** [sqlite3_libversion_number()], [sqlite3_sourceid()],
263459263486** [sqlite_version()] and [sqlite_source_id()].
263460263487*/
263461- #define SQLITE_VERSION "3.50.3 "
263462- #define SQLITE_VERSION_NUMBER 3050003
263463- #define SQLITE_SOURCE_ID "2025-07-17 13:25:10 3ce993b8657d6d9deda380a93cdd6404a8c8ba1b185b2bc423703e41ae5f2543 "
263488+ #define SQLITE_VERSION "3.50.4 "
263489+ #define SQLITE_VERSION_NUMBER 3050004
263490+ #define SQLITE_SOURCE_ID "2025-07-30 19:33:53 4d8adfb30e03f9cf27f800a2c1ba3c48fb4ca1b08b0f5ed59a4d5ecbf45e20a3 "
263464263491
263465263492/*
263466263493** CAPI3REF: Run-Time Library Version Numbers
@@ -331263,7 +331290,7 @@ sqlite3mcBtreeSetPageSize(Btree* p, int pageSize, int nReserve, int iFix)
331263331290** Change 4: Call sqlite3mcBtreeSetPageSize instead of sqlite3BtreeSetPageSize for main database
331264331291** (sqlite3mcBtreeSetPageSize allows to reduce the number of reserved bytes)
331265331292**
331266- ** This code is generated by the script rekeyvacuum.sh from SQLite version 3.50.3 amalgamation.
331293+ ** This code is generated by the script rekeyvacuum.sh from SQLite version 3.50.4 amalgamation.
331267331294*/
331268331295SQLITE_PRIVATE SQLITE_NOINLINE int sqlite3mcRunVacuumForRekey(
331269331296 char **pzErrMsg, /* Write error message here */
0 commit comments