4. Creating a Database and Loading Data : Statistics for the Query Optimizer
Share this page                  
Statistics for the Query Optimizer
Vector uses a query optimizer to develop sophisticated query execution strategies. Statistics must be generated that tell the query optimizer what your data looks like. The query optimizer uses the statistics to generate a query execution plan (QEP) that shows how your query is executed. The QEP can be reused to execute the same query.
Vector automatically generates statistics after the server is started but you can control the generation of statistics by using the optimizedb command or CREATE STATISTIC statement.
To run optimizedb on the database dbtest
Issue the following command from the command line:
optimizedb -zns dbtest
The -zns flag speeds the building of the histogram.
For more information on the query optimizer, see the User Guide.