KEMBAR78
Query optimization and performance | PPTX
Query
optimization and
performance
Basic Query Processing
Steps… Query Parsing and Translation(Query compiler)
• check the syntax (e.g. SQL for relational DBMS)
• Verify that the mentioned relations do exist and replace views
• Transform the SQL query to a query plan represented by a relational
algebra expression (for relational DBMS)
 Different possible relational algebra expression for a single query
 Query Optimization(query optimizer)
• Transform the initial query plan into the best possible query plan based
on the given data set
 Specify the execution of single query plan operations(evaluation
primitives)
 E.g. which algo and indices to be used
 The query execution plan is defined by a saquence of evaluation
primitives
 Query evaluation (command processor)
• Execute the query execution plan and return the result

Query optimization and performance

  • 1.
  • 3.
    Basic Query Processing Steps…Query Parsing and Translation(Query compiler) • check the syntax (e.g. SQL for relational DBMS) • Verify that the mentioned relations do exist and replace views • Transform the SQL query to a query plan represented by a relational algebra expression (for relational DBMS)  Different possible relational algebra expression for a single query  Query Optimization(query optimizer) • Transform the initial query plan into the best possible query plan based on the given data set  Specify the execution of single query plan operations(evaluation primitives)  E.g. which algo and indices to be used  The query execution plan is defined by a saquence of evaluation primitives  Query evaluation (command processor) • Execute the query execution plan and return the result