Evaluating Parallel Query in Parallel Databases

Techniques of query Evaluation

The two techniques used in query evaluation are as follows:

1. Inter query parallelism
  • This technique allows to run multiple queries on different processors simultaneously.
  • Pipelined parallelism is achieved by using inter query parallelism, which improves the output of the system.

  • For example: If there are 6 queries, each query will take 3 seconds for evaluation. Thus, the total time taken to complete evaluation process is 18 seconds. Inter query parallelism achieves this task only in 3 seconds.
  • However, Inter query parallelism is difficult to achieve every time.
2. Intra Query Parallelism
  • In this technique query is divided in sub queries which can run simultaneously on different processors, this will minimize the query evaluation time.
  • Intra query parallelism improves the response time of the system.

  • For Example: If we have 6 queries, which can take 3 seconds to complete the evaluation process, the  total time to complete the evaluation process is 18 seconds. But We can achieve this task in only 3 seconds by using intra query evaluation as each query is divided in sub-queries.

Optimization of Parallel Query

  • Parallel Query optimization is nothing but selecting the efficient query evaluation plan.
  • Parallel Query optimization plays an important role in developing system to minimize the cost of query evaluation.
Two factors play a very important in parallel query optimization.

a) total time spent to find the best plan.
b) amount of time required to execute the plan.

Goals of Query optimization.

Query Optimization is done with an aim to:
  • Speed up the queries by finding the queries which can give the fastest result on execution.
  • Increase the performance of the system.
  • Select the best query evaluation plan.
  • Avoid the unwanted plan.

Approaches of Query Optimization.

Following are the three approaches to Query Optimization:

1. Horizontal partitioning: Tables are created vertically using columns.
2. Vertical partitioning: Tables are created with fewer columns and partition the table row wise.
3. De-normalization: In this approach multiple tables are combined into one table.