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

Column pruning doesn't work for EXPLAIN ANALYZE #4760

Closed
martint opened this issue Aug 10, 2020 · 0 comments · Fixed by #5173
Closed

Column pruning doesn't work for EXPLAIN ANALYZE #4760

martint opened this issue Aug 10, 2020 · 0 comments · Fixed by #5173
Assignees
Labels
bug Something isn't working

Comments

@martint
Copy link
Member

martint commented Aug 10, 2020

EXPLAIN SELECT orderkey FROM orders
 Fragment 0 [SINGLE]
     Output layout: [orderkey]
     Output partitioning: SINGLE []
     Stage Execution Strategy: UNGROUPED_EXECUTION
     Output[orderkey]
     │   Layout: [orderkey:bigint]
     │   Estimates: {rows: 15000 (131.84kB), cpu: 131.84k, memory: 0B, network: 131.84kB}
     └─ RemoteSource[1]
            Layout: [orderkey:bigint]

 Fragment 1 [tpch:orders:15000]
     Output layout: [orderkey]
     Output partitioning: SINGLE []
     Stage Execution Strategy: UNGROUPED_EXECUTION
     TableScan[tpch:orders:sf0.01, grouped = false]
         Layout: [orderkey:bigint]
         Estimates: {rows: 15000 (131.84kB), cpu: 131.84k, memory: 0B, network: 0B}
         orderkey := tpch:orderkey
         tpch:orderstatus
             :: [[F], [O], [P]]

But:

EXPLAIN ANALYZE SELECT orderkey FROM orders

Ignores the fact that only orderkey is being selected and produces:

 Fragment 1 [tpch:orders:15000]
     CPU: 204.29ms, Scheduled: 397.88ms, Input: 15000 rows (1.99MB); per task: avg.: 5000.00 std.dev.: 11.31, Output: 15000 rows (1.99MB)
     Output layout: [orderkey, custkey, orderstatus, totalprice, orderdate, orderpriority, clerk, shippriority, comment, row_number]
     Output partitioning: SINGLE []
     Stage Execution Strategy: UNGROUPED_EXECUTION
     TableScan[tpch:orders:sf0.01, grouped = false]
         Layout: [orderkey:bigint, custkey:bigint, orderstatus:varchar(1), totalprice:double, orderdate:date, orderpriority:varchar(15), clerk:varchar(15), shippriority:integer, comment:varchar(79), row_number:bigint]
         Estimates: {rows: 15000 (1.65MB), cpu: 1.65M, memory: 0B, network: 0B}
         CPU: 201.00ms (100.00%), Scheduled: 380.00ms (100.00%), Output: 15000 rows (1.99MB)
         Input avg.: 416.67 rows, Input std.dev.: 0.95%
         clerk := tpch:clerk
         orderkey := tpch:orderkey
         orderstatus := tpch:orderstatus
             :: [[F], [O], [P]]
         custkey := tpch:custkey
         totalprice := tpch:totalprice
         comment := tpch:comment
         row_number := tpch:row_number
         orderdate := tpch:orderdate
         orderpriority := tpch:orderpriority
         shippriority := tpch:shippriority
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Development

Successfully merging a pull request may close this issue.

2 participants