Cost Based Optimization (CBO) Statistics Injector
Details
| Detail name | Value |
|---|---|
| Changelog Number | 5351 |
| Type | New Feature |
| Status | Resolved |
| Fix Versions | EXASOL 6.0.7 |
| Resolution Date | 2018-08-08 |
Feature
Cost Based Optimization (CBO) Injector is a means to export CBO Statistics from production systems. These statistics can be "injected" in test systems by developers to precisely reproduce performance issues faced by users due to incorrect join queues produced by the SQL compiler. This will further help developers in analyzing the impact of their changes to the CBO and provide reliable solutions to customers.
Problem
Exasol uses Cost Based Optimizer (CBO) to generate an optimal join queue based on some statistics about the join tables.
While we constantly work on improving the cost based optimization strategies, real-life usage scenarios are often difficult to generate in our tests. Bugs in CBO can lead to sub-optimal join queues and poor performance of customer queries.
These bugs are difficult to reproduce and feedback loop between customers and developers is often tedious and time consuming.
Usage
1. To enable logging of CBO statistics, the customers must run the following command before running the query.
CONTROL ENABLE LOG CBO STATISTICS;
Hereafter, the customer will run the queries and the Exasol SQL compiler will dump the CBO Statistics in the Sessions log file.
2. After the execution of the query, the customers can disable the logging of CBO Statistics using the following command.
CONTROL DISABLE LOG CBO STATISTICS;