Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(planner): Add statistics info in explain result #7401

Merged
merged 3 commits into from
Aug 30, 2022

Conversation

leiysky
Copy link
Contributor

@leiysky leiysky commented Aug 30, 2022

I hereby agree to the terms of the CLA available at: https://databend.rs/dev/policies/cla/

Summary

Example:

mysql> explain select number+1 from numbers(10);
+----------------------------------------------------------+
| explain                                                  |
+----------------------------------------------------------+
| Project                                                  |
| ├── columns: [1]                                         |
| └── EvalScalar                                           |
|     ├── expressions: [+(numbers.number, 1)]              |
|     └── TableScan                                        |
|         ├── table: default.system.numbers                |
|         ├── read rows: 10                                |
|         ├── read bytes: 80                               |
|         ├── partitions total: 1                          |
|         ├── partitions scanned: 1                        |
|         └── push downs: [filters: [], limit: NONE]       |
+----------------------------------------------------------+
11 rows in set (0.02 sec)
Read 0 rows, 0.00 B in 0.005 sec., 0 rows/sec., 0.00 B/sec.

Close #7350

@vercel
Copy link

vercel bot commented Aug 30, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Updated
databend ⬜️ Ignored (Inspect) Aug 30, 2022 at 3:59PM (UTC)

@mergify mergify bot added the pr-chore this PR only has small changes that no need to record, like coding styles. label Aug 30, 2022
@BohuTANG
Copy link
Member

Many logic tests failed(due to the explain format):
https://github.com/datafuselabs/databend/runs/8093212379?check_suite_focus=true#step:4:1244

Copy link
Member

@BohuTANG BohuTANG left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@BohuTANG BohuTANG merged commit ecdd853 into databendlabs:main Aug 30, 2022
@BohuTANG
Copy link
Member

Please document the EXPLAIN statement in https://databend.rs/doc/reference/sql/explain-commands, thanks @soyeric128

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr-chore this PR only has small changes that no need to record, like coding styles.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feat: add statistics back to new planner explain
2 participants