About cookies on this site Our websites require some cookies to function properly (required). In addition, other cookies may be used with your consent to analyze site usage, improve the user experience and for advertising. For more information, please review your options. By visiting our website, you agree to our processing of information as described in IBM’sprivacy statement. To provide a smooth navigation, your cookie preferences will be shared across the IBM web domains listed here.
Last updated: Nov 26, 2024
You can use the SYSPROC.NNSTAT procedure to collect statistics for all virtualized objects except those that are defined in object storage.
Important: Do not use the SYSPROC.NNSTAT procedure (a catalog-based statistics
collection method) on a virtualized table. This approach deletes any previously collected
column-level statistics, which has an adverse impact on query performance.
The following example shows you how to call the SYSPROC.NNSTAT procedure to collect statistics.
call SYSPROC.NNSTAT(NULL, 'schema', 'table_name', 'list_of_columns_commonly_used_in_predicates', '', 2, '/tmp/table_name.log', ?, 1);
This call collects table-level statistics and column-level statistics for the columns that are included in the list_of_columns_commonly_used_in_predicates argument. If the table has a small number of columns, you can collect statistics for all columns in the table by specifying the null value instead of a column list. To avoid collecting column statistics, specify the empty string ('') instead.
For more information, see the SYSPROC.NNSTAT stored procedure.
Was the topic helpful?
0/1000