Commit Graph

15 Commits

Author SHA1 Message Date
drh
175b8f06f7 Remove support for STAT3. The sqlite_stat3 tables are ignored, if they
exist.  STAT4 continues to work as it always has, and as it is a superset of
STAT3 is the recommended replacement.

FossilOrigin-Name: 1e17ea2fd1df4ad49138c787c8fe3207dd0c25c93f9001d52a9b69f8c12e841c
2019-08-08 15:24:17 +00:00
dan
8ad169abb4 If ENABLE_STAT3 is defined but ENABLE_STAT4 is not, have ANALYZE create and populate the sqlite_stat3 table instead of sqlite_stat4.
FossilOrigin-Name: cca8bf4372ab7a0258aa5c9397818415c6cf0abf
2013-08-12 20:14:04 +00:00
dan
dd6e1f193e Add the rowid field to the end of sample records stored in the sqlite_stat4 table.
FossilOrigin-Name: 3a5e8ab7ddbe1d943b35ef329fe4e5a1bfdb0d9d
2013-08-10 19:08:30 +00:00
dan
f52bb8d385 Begin adding experimental sqlite_stat4 table. This commit is buggy.
FossilOrigin-Name: 2beea303a1d609cd2ff252412c50b966b9e5e8f1
2013-08-03 20:24:58 +00:00
drh
8636e9c55c Handle virtual tables correctly when using logarithmic costs. Fixes
to test cases.

FossilOrigin-Name: e612664aa2e24ed5e222be2c7fe16e210ac9bded
2013-06-11 01:50:08 +00:00
drh
4e50c5ec48 Further testing and bug fixing for sqlite_stat3. Added the Index.avgEq
field to index statistics.  Fixed several problems in the query planner
associated with stat3.

FossilOrigin-Name: 89b2f70884cad0abdf4c66cb64ecddb2820ded74
2011-08-13 19:35:19 +00:00
drh
ea6dc4458b Always make sure the left-hand side of the IS NOT NULL operator is a
smiple column, not a general expression, before applying the IS NOT NULL
query optimization.

FossilOrigin-Name: 543f75a6abe3aa4f49df43e71a462702d40b3251
2011-04-08 21:35:26 +00:00
drh
1f9c7663ce Enhances to the query planner such that "x IS NULL" constraints take the
STAT2 statistics into account, just like "x=VALUE" constraints.

FossilOrigin-Name: 2353176811f752a16c1f2351a3d3431919b062a9
2011-03-17 01:34:26 +00:00
drh
3772206769 Refactor the cost function in the query planner. Give extra cost (thus
reduce likelihood of selection) to full table scans.

FossilOrigin-Name: 878da276ebf643b716ddd650d4d0ca3595fe5bf2
2011-02-10 00:08:47 +00:00
drh
40ad34c608 Reactivate the analyze5.test script.
FossilOrigin-Name: a2a9f6401c927f6259cda3ba35219cabef24e84d
2011-01-28 03:13:58 +00:00
drh
fc4491366b Restructuring and generalizing analyze5.test. The whole script is
currently disabled and will need to be reenabled prior to merging with trunk.

FossilOrigin-Name: 31fcc7067bd76da4bf19232811b90cf8b76eed74
2011-01-24 17:46:35 +00:00
drh
5ac0607169 Adjustments to the result row estimator for the IN operator so that it gives
the same estimates as the equivalent OR operator.  Test cases for the same.

FossilOrigin-Name: c82cb9c028b3ba5463ae50c30196dbf157a7a305
2011-01-21 18:18:13 +00:00
drh
3851b74ae1 Update ANALYZE test cases to check out the use of histograms for equality
constraints.

FossilOrigin-Name: c7b59afaf0c0bf85dbaf0a122cc8d65fca93680f
2011-01-20 20:36:13 +00:00
drh
82759754ce Use histogram data to improve the row-count estimates on equality constraints.
FossilOrigin-Name: 6bfc5c69eb22938972bbf4e60179952dc215f770
2011-01-20 16:52:09 +00:00
drh
e847d3247f The first of a planned series of enhancements to the query planner that
enable it to make better use of sqlite_stat2 histograms when the table
has many repeated values.

FossilOrigin-Name: 2cd374cd23fa2fd38f49090d6eeb9b1e521d51d5
2011-01-20 02:56:37 +00:00