Description
Currently, the AQE plan string displays both the initial plan and the current or the final plan. This can be redundant when the initial plan and the current physical plan are exactly the same. For instance, the `EXPLAIN` command will not actually execute the query, and thus the plan string will never change, but currently, the plan string still shows both the current and the initial plan:
AdaptiveSparkPlan (8) +- == Current Plan == Sort (7) +- Exchange (6) +- HashAggregate (5) +- Exchange (4) +- HashAggregate (3) +- Filter (2) +- Scan parquet default.explain_temp1 (1) +- == Initial Plan == Sort (7) +- Exchange (6) +- HashAggregate (5) +- Exchange (4) +- HashAggregate (3) +- Filter (2) +- Scan parquet default.explain_temp1 (1)
When the initial and the current plan are the same, there should be only one plan string displayed. For example
AdaptiveSparkPlan (8)
+- Sort (7)
+- Exchange (6)
+- HashAggregate (5)
+- Exchange (4)
+- HashAggregate (3)
+- Filter (2)
+- Scan parquet default.explain_temp1 (1)