[MDEV-9118] ANALYZE TABLE for Engine independent status fetches blob/text columns without use Created: 2015-11-12 Updated: 2016-01-22 Resolved: 2016-01-22 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Optimizer |
| Fix Version/s: | 10.1.11 |
| Type: | Task | Priority: | Major |
| Reporter: | Daniel Black | Assignee: | Oleksandr Byelkin |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | eits | ||
| Issue Links: |
|
||||||||||||
| Sprint: | 10.1.10, 10.1.11 | ||||||||||||
| Description |
|
From |
| Comments |
| Comment by Oleksandr Byelkin [ 2015-12-16 ] | ||||||||||||||||||||
|
I am not sure if BLOB should be ignored if it is explicitly mentioned in the fields list. Also I am not sure if warning should be issued. revision-id: c9e76fec68476b7987cc6ce0a0a74d9d492854e0 (mariadb-10.1.9-20-gc9e76fe)
Do not include BLOB fields by default. — | ||||||||||||||||||||
| Comment by Sergei Petrunia [ 2015-12-16 ] | ||||||||||||||||||||
|
I think: if the blob column was explicitly mentioned, but we are not collecting statistics, a warning should be issued. Now, to the question of what to do when ANALYZE explicitly mentions a blob column:
column names are:
One can see that min_value and max_value are not saved. nulls_ratio and avg_length are saved. | ||||||||||||||||||||
| Comment by Sergei Petrunia [ 2015-12-16 ] | ||||||||||||||||||||
|
Trying to check whether nulls_ratio can be used... | ||||||||||||||||||||
| Comment by Sergei Petrunia [ 2015-12-17 ] | ||||||||||||||||||||
|
Yes, it can be:
Debugging an ANALYZE TABLE t1 PERSISTENT FOR ALL, I see that column b doesn't have a Unique object. So, does it make sense to collect some stats for blobs after all? | ||||||||||||||||||||
| Comment by Sergei Petrunia [ 2015-12-17 ] | ||||||||||||||||||||
|
.. but if that is enabled, one can also try producing selectivities for other columns, as well. sanja, I think that for now the code should never collect stats for a blob column. if the column is specified explicitly, emit a warning "Engine-independent statistics are not collected for column %s". | ||||||||||||||||||||
| Comment by Oleksandr Byelkin [ 2015-12-18 ] | ||||||||||||||||||||
|
revision-id: aa67fa247f9758b8361a79fb560ad44ef02397d3 (mariadb-10.1.9-20-gaa67fa2)
Do not include BLOB fields by default. — | ||||||||||||||||||||
| Comment by Oleksandr Byelkin [ 2015-12-18 ] | ||||||||||||||||||||
|
revision-id: 59fcd7ff2315d007045eb987da5f21abbea6f6f1 (mariadb-10.1.9-20-g59fcd7f)
Do not include BLOB fields by default. — | ||||||||||||||||||||
| Comment by Sergei Petrunia [ 2015-12-22 ] | ||||||||||||||||||||
|
Review feedback sent over email. |