alamb opened a new issue, #15019: URL: https://github.com/apache/datafusion/issues/15019
### Is your feature request related to a problem or challenge? - Part of https://github.com/apache/datafusion/issues/14914 The new tree explain format currently truncates pretty aggressively For example, the query like this ```sql set datafusion.explain.format = "tree"; create table table1 ( int_col INT, string_col TEXT, bigint_col BIGINT, date_col DATE ) as VALUES (1, 'foo', 1, '2023-01-01'), (2, 'bar', 2, '2023-01-02'), (3, 'baz', 3, '2023-01-03'); 0 row(s) fetched. explain SELECT int_col FROM table1 WHERE string_col != 'foo' AND string_col != 'bar' AND string_col != 'a really long string constant' ``` The output looks like this (note that the predicate has been truncated): ```sql +---------------+------------------------------------------------------------------------------------------------------------------------------------------------+ | plan_type | plan | +---------------+------------------------------------------------------------------------------------------------------------------------------------------------+ | logical_plan | Projection: table1.int_col | | | Filter: table1.string_col != Utf8("foo") AND table1.string_col != Utf8("bar") AND table1.string_col != Utf8("a really long string constant") | | | TableScan: table1 projection=[int_col, string_col] | | physical_plan | ┌───────────────────────────┐ | | | │ CoalesceBatchesExec │ | | | └─────────────┬─────────────┘ | | | ┌─────────────┴─────────────┐ | | | │ FilterExec │ | | | │ -------------------- │ | | | │ predicate: │ | | | │string_col@1 != foo AND ...│ | | | └─────────────┬─────────────┘ | | | ┌─────────────┴─────────────┐ | | | │ DataSourceExec │ | | | │ -------------------- │ | | | │ partition_sizes: [1] │ | | | │ partitions: 1 │ | | | └───────────────────────────┘ | | | | +---------------+------------------------------------------------------------------------------------------------------------------------------------------------+ 2 row(s) fetched. ``` As @irenjj says in https://github.com/apache/datafusion/pull/15001#discussion_r1979377790 > This is a very nice case for `// TODO: check every line is less than MAX_LINE_RENDER_SIZE`. In DuckDB, we can get the following result: ``` D explain select * from t1 where c != 'foo' and c != 'bar' and c != 'a really long string constant'; ┌─────────────────────────────┐ │┌───────────────────────────┐│ ││ Physical Plan ││ │└───────────────────────────┘│ └─────────────────────────────┘ ┌───────────────────────────┐ │ SEQ_SCAN │ │ ──────────────────── │ │ Table: t1 │ │ Type: Sequential Scan │ │ Projections: c │ │ │ │ Filters: │ │ c!='foo' AND c!='bar' AND │ │ c!='a really long string │ │ constant' │ │ │ │ ~1 Rows │ └───────────────────────────┘ ``` ### Describe the solution you'd like I would like more of the predicate to be visible in the explain plan (there probably needs to still be some limit, but more than one line would be nice) ### Describe alternatives you've considered _No response_ ### Additional context _No response_ -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org