The following operations are required to generate a query execution plan:

  • A controller node receives query requests and parses SQL statements.
  • The optimizer analyzes the parsed SQL statements to evaluate whether it is necessary to rewrite the query tree to improve query performance.
  • The optimizer generates an optimal logical execution plan to specify a specific execution processing method, such as the join type, join sequence, aggregation method, and data redistribution method.
  • An executor node converts the received logical execution plan into a physical execution plan.