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

Avoid adding superfluous virtual WHERE clause terms that might arise due

to the constant propagation optimization.

FossilOrigin-Name: cf63abbe559d04f993f99a37d41ba4a97c0261094f1d4cc05cfa23b1e11731f5
This commit is contained in:
drh
2021-05-14 15:37:00 +00:00
parent b775c97682
commit 6a9595a76b
4 changed files with 14 additions and 12 deletions

View File

@ -28,11 +28,11 @@ do_eqp_test 110 {
QUERY PLAN
`--COMPOUND QUERY
|--LEFT-MOST SUBQUERY
| |--SEARCH t2 USING INDEX sqlite_autoindex_t2_1 (a=?)
| `--SEARCH t1 USING INDEX sqlite_autoindex_t1_1 (a=?)
| |--SEARCH t1 USING INDEX sqlite_autoindex_t1_1 (a=?)
| `--SEARCH t2 USING INDEX sqlite_autoindex_t2_1 (a=?)
`--UNION ALL
|--SEARCH t3 USING INDEX sqlite_autoindex_t3_1 (a=?)
`--SEARCH t1 USING INDEX sqlite_autoindex_t1_1 (a=?)
|--SEARCH t1 USING INDEX sqlite_autoindex_t1_1 (a=?)
`--SEARCH t3 USING INDEX sqlite_autoindex_t3_1 (a=?)
}
# The scan of the t1 table goes first since that enables the ORDER BY