6. Statistics

Zetaris Cloud Data Fabric comes up with a CBO (Cost Based Optimiser) to reduce data shuffling across clusters and data sources.
To do this, Zetaris Cloud Data Fabric keeps table-level statistics and column-level statistics for all data sources defined in its Schema Store.

Table level statistics

To generate statistics such as size in bytes, cardinality for the table
ANALYZE DATASOURCE TABLE ORCL.MOVIES


To show the generated table statistics

SHOW DATASOURCE TABLE STATISTICS ORCL.MOVIES
 
Column level statistics
To generate statistics for a column such as cardinality, number of null, min, max, average value.
ANALYZE DATASOURCE TABLE ORCL.MOVIES COMPUTE STATISTICS FOR COLUMNS(IID, TITLE)


To show the generated column statistics

SHOW DATASOURCE COLUMN STATISTICS ORCL.MOVIES