1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-29 08:01:23 +03:00

Make the SQLITE_DBCONFIG_STMT_SCANSTATUS option on by default.

FossilOrigin-Name: 5a09191186bc03b374e0c0d029e1a15208c6b845bc2f5f5f9f6a8a882809d9f3
This commit is contained in:
dan
2023-03-03 21:17:12 +00:00
parent fe52615925
commit 3410e550dc
8 changed files with 31 additions and 21 deletions

View File

@ -100,6 +100,7 @@ do_eqp_test 4.2 {
|--MATERIALIZE rr
| `--SCAN ft4 VIRTUAL TABLE INDEX 3:
|--SCAN t4
|--BLOOM FILTER ON rr (docid=?)
`--SEARCH rr USING AUTOMATIC COVERING INDEX (docid=?) LEFT-JOIN
}

View File

@ -45,17 +45,20 @@ proc do_scanstatus_test {tn res} {
uplevel [list do_test $tn [list set {} $ret] [list {*}$res]]
}
do_execsql_test 1.0a { SELECT count(*) FROM t1, t2; } 6
do_scanstatus_test 1.0b { }
sqlite3_db_config db STMT_SCANSTATUS 1
do_execsql_test 1.1 { SELECT count(*) FROM t1, t2; } 6
do_scanstatus_test 1.2 {
do_execsql_test 1.1a { SELECT count(*) FROM t1, t2; } 6
do_scanstatus_test 1.1b {
nLoop 1 nVisit 2 nEst 1048576.0 zName t1 zExplain {SCAN t1}
nLoop 2 nVisit 6 nEst 1048576.0 zName t2 zExplain {SCAN t2}
}
sqlite3_db_config db STMT_SCANSTATUS 0
do_execsql_test 1.2a { SELECT count(*) FROM t1, t2; } 6
do_scanstatus_test 1.2b {
}
sqlite3_db_config db STMT_SCANSTATUS 1
do_execsql_test 1.3 {
ANALYZE;
SELECT count(*) FROM t1, t2;