1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-30 19:03:16 +03:00

Merge trunk testing enhancements into the pushdown-subquery branch.

FossilOrigin-Name: 287ff24b26a512ff7648679767e68244f6eef95df6a49c46ed1f2594030ed523
This commit is contained in:
drh
2024-04-07 18:55:57 +00:00
4 changed files with 13 additions and 46 deletions

View File

@ -1,5 +1,5 @@
C Merge\strunk\senhancements\sinto\sthe\spushdown-subquery\sbranch. C Merge\strunk\stesting\senhancements\sinto\sthe\spushdown-subquery\sbranch.
D 2024-04-07T10:30:29.186 D 2024-04-07T18:55:57.788
F .fossil-settings/empty-dirs dbb81e8fc0401ac46a1491ab34a7f2c7c0452f2f06b54ebb845d024ca8283ef1 F .fossil-settings/empty-dirs dbb81e8fc0401ac46a1491ab34a7f2c7c0452f2f06b54ebb845d024ca8283ef1
F .fossil-settings/ignore-glob 35175cdfcf539b2318cb04a9901442804be81cd677d8b889fcc9149c21f239ea F .fossil-settings/ignore-glob 35175cdfcf539b2318cb04a9901442804be81cd677d8b889fcc9149c21f239ea
F LICENSE.md df5091916dbb40e6e9686186587125e1b2ff51f022cc334e886c19a0e9982724 F LICENSE.md df5091916dbb40e6e9686186587125e1b2ff51f022cc334e886c19a0e9982724
@ -748,7 +748,7 @@ F src/pragma.h e690a356c18e98414d2e870ea791c1be1545a714ba623719deb63f7f226d8bb7
F src/prepare.c 371f6115cb69286ebc12c6f2d7511279c2e47d9f54f475d46a554d687a3b312c F src/prepare.c 371f6115cb69286ebc12c6f2d7511279c2e47d9f54f475d46a554d687a3b312c
F src/printf.c 87b67bba3662a0523f39ae6b084a3907109702f717c654d6cecb838af5cd57f1 F src/printf.c 87b67bba3662a0523f39ae6b084a3907109702f717c654d6cecb838af5cd57f1
F src/random.c 606b00941a1d7dd09c381d3279a058d771f406c5213c9932bbd93d5587be4b9c F src/random.c 606b00941a1d7dd09c381d3279a058d771f406c5213c9932bbd93d5587be4b9c
F src/resolve.c f242e509b2ff9e31799d26ddd87f20db1124426203aa16833a694d401b50d650 F src/resolve.c 6310bdfed32184cd3a5d6ba203dfee1ea323051cb38a6c2e80a5b79c069f4e87
F src/rowset.c 8432130e6c344b3401a8874c3cb49fefe6873fec593294de077afea2dce5ec97 F src/rowset.c 8432130e6c344b3401a8874c3cb49fefe6873fec593294de077afea2dce5ec97
F src/select.c 51893b3e34d38ad8d46b5010a6e380ca878b578be5001a640daa907336187424 F src/select.c 51893b3e34d38ad8d46b5010a6e380ca878b578be5001a640daa907336187424
F src/shell.c.in 0354ca51eee5fbf6af394a7ef9f5ef6823ef45b743db65431f6777e4d5be2199 F src/shell.c.in 0354ca51eee5fbf6af394a7ef9f5ef6823ef45b743db65431f6777e4d5be2199
@ -1258,7 +1258,7 @@ F test/fuzzdata8.db 4a53b6d077c6a5c23b609d8d3ac66996fa55ba3f8d02f9b6efdd0214a767
F test/fuzzer1.test 3d4c4b7e547aba5e5511a2991e3e3d07166cfbb8 F test/fuzzer1.test 3d4c4b7e547aba5e5511a2991e3e3d07166cfbb8
F test/fuzzer2.test a85ef814ce071293bce1ad8dffa217cbbaad4c14 F test/fuzzer2.test a85ef814ce071293bce1ad8dffa217cbbaad4c14
F test/fuzzerfault.test f64c4aef4c9e9edf1d6dc0d3f1e65dcc81e67c996403c88d14f09b74807a42bc F test/fuzzerfault.test f64c4aef4c9e9edf1d6dc0d3f1e65dcc81e67c996403c88d14f09b74807a42bc
F test/fuzzinvariants.c 9fc6810dde21e1aee20ed7a6c8ed944ffee127cf082fc48caba398fa31c762ca F test/fuzzinvariants.c d89b81c3bdad7b2837f8cce645d5b563ffa965f6d819ce33f0f6d82a71c6ca9a
F test/gcfault.test 4ea410ac161e685f17b19e1f606f58514a2850e806c65b846d05f60d436c5b0d F test/gcfault.test 4ea410ac161e685f17b19e1f606f58514a2850e806c65b846d05f60d436c5b0d
F test/gencol1.test e169bdfa11c7ed5e9f322a98a7db3afe9e66235750b68c923efee8e1876b46ec F test/gencol1.test e169bdfa11c7ed5e9f322a98a7db3afe9e66235750b68c923efee8e1876b46ec
F test/genesis.tcl 1e2e2e8e5cc4058549a154ff1892fe5c9de19f98 F test/genesis.tcl 1e2e2e8e5cc4058549a154ff1892fe5c9de19f98
@ -2184,8 +2184,8 @@ F vsixtest/vsixtest.tcl 6a9a6ab600c25a91a7acc6293828957a386a8a93
F vsixtest/vsixtest.vcxproj.data 2ed517e100c66dc455b492e1a33350c1b20fbcdc F vsixtest/vsixtest.vcxproj.data 2ed517e100c66dc455b492e1a33350c1b20fbcdc
F vsixtest/vsixtest.vcxproj.filters 37e51ffedcdb064aad6ff33b6148725226cd608e F vsixtest/vsixtest.vcxproj.filters 37e51ffedcdb064aad6ff33b6148725226cd608e
F vsixtest/vsixtest_TemporaryKey.pfx e5b1b036facdb453873e7084e1cae9102ccc67a0 F vsixtest/vsixtest_TemporaryKey.pfx e5b1b036facdb453873e7084e1cae9102ccc67a0
P 8682931f9c6b40e1b09139c10bbe932c38330b5eb0c5c84f2432ad19a6793e37 3d5fb1ec7a0440072d6e3b957903c85d0f32b8b07207a1ef22d1a69cf5e664d1 P 27865e316f8dfbf4c20290cf1be3024d7518fec46655e34f3fc435e15346c63e 6431538f0bb3bb8606786f3c3e5c055c4bc387098dd3bdc8a94f6fda61c47f52
R 1c8ec3969a2f62f321843779b94d95c0 R a6f74894c0cda8635456b45fc1556948
U drh U drh
Z 01f0a53bbc70dd3f39888afc9b26be49 Z d0677700c03f1b93b120f5cc4adf200f
# Remove this line to create a well-formed Fossil manifest. # Remove this line to create a well-formed Fossil manifest.

View File

@ -1 +1 @@
27865e316f8dfbf4c20290cf1be3024d7518fec46655e34f3fc435e15346c63e 287ff24b26a512ff7648679767e68244f6eef95df6a49c46ed1f2594030ed523

View File

@ -632,6 +632,11 @@ static int lookupName(
&& ALWAYS(VisibleRowid(pMatch->pTab) || pMatch->fg.isNestedFrom) && ALWAYS(VisibleRowid(pMatch->pTab) || pMatch->fg.isNestedFrom)
){ ){
cnt = cntTab; cnt = cntTab;
#if SQLITE_ALLOW_ROWID_IN_VIEW+0==2
if( pMatch->pTab!=0 && IsView(pMatch->pTab) ){
eNewExprOp = TK_NULL;
}
#endif
if( pMatch->fg.isNestedFrom==0 ) pExpr->iColumn = -1; if( pMatch->fg.isNestedFrom==0 ) pExpr->iColumn = -1;
pExpr->affExpr = SQLITE_AFF_INTEGER; pExpr->affExpr = SQLITE_AFF_INTEGER;
} }

View File

@ -223,19 +223,6 @@ not_a_fault:
return SQLITE_OK; return SQLITE_OK;
} }
#ifdef SQLITE_ALLOW_ROWID_IN_VIEW
/*
** Return TRUE if the i-th column of pStmt might be a ROWID value.
*/
static int column_might_be_rowid(sqlite3_stmt *pStmt, int i){
const char *zColName = sqlite3_column_name(pStmt, i);
if( sqlite3_strlike("%rowid%",zColName,0)==0 ) return 1;
if( sqlite3_strlike("%oid%",zColName,0)==0 ) return 1;
return 0;
}
#endif /* SQLITE_ALLOW_ROWID_IN_VIEW */
/* /*
** Generate SQL used to test a statement invariant. ** Generate SQL used to test a statement invariant.
** **
@ -308,12 +295,6 @@ static char *fuzz_invariant_sql(sqlite3_stmt *pStmt, int iCnt){
** WHERE clause. */ ** WHERE clause. */
continue; continue;
} }
#ifdef SQLITE_ALLOW_ROWID_IN_VIEW
if( column_might_be_rowid(pBase,i) ){
/* ROWID values are unreliable if SQLITE_ALLOW_ROWID_IN_VIEW is used */
continue;
}
#endif
for(j=0; j<i; j++){ for(j=0; j<i; j++){
const char *zPrior = sqlite3_column_name(pBase, j); const char *zPrior = sqlite3_column_name(pBase, j);
if( sqlite3_stricmp(zPrior, zColName)==0 ) break; if( sqlite3_stricmp(zPrior, zColName)==0 ) break;
@ -342,11 +323,6 @@ static char *fuzz_invariant_sql(sqlite3_stmt *pStmt, int iCnt){
/* /*
** Return true if and only if v1 and is the same as v2. ** Return true if and only if v1 and is the same as v2.
**
** When compiled with SQLITE_ALLOW_ROWID_IN_VIEW, and if either
** v1 or v2 has a column name that indicates that it is a rowid
** then a NULL value in the rowid column will compare equal to
** an integer value in the other.
*/ */
static int sameValue( static int sameValue(
sqlite3_stmt *pS1, int i1, /* Value to text on the left */ sqlite3_stmt *pS1, int i1, /* Value to text on the left */
@ -361,20 +337,6 @@ static int sameValue(
|| (t1==SQLITE_FLOAT && t2==SQLITE_INTEGER) || (t1==SQLITE_FLOAT && t2==SQLITE_INTEGER)
){ ){
/* Comparison of numerics is ok */ /* Comparison of numerics is ok */
#ifdef SQLITE_ALLOW_ROWID_IN_VIEW
}else
if( t1==SQLITE_INTEGER
&& t2==SQLITE_NULL
&& column_might_be_rowid(pS2,i2)
){
return 1;
}else
if( t2==SQLITE_INTEGER
&& t1==SQLITE_NULL
&& column_might_be_rowid(pS1,i1)
){
return 1;
#endif /* SQLITE_ALLOW_ROWID_IN_VIEW */
}else{ }else{
return 0; return 0;
} }