淘先锋技术网

首页 1 2 3 4 5 6 7

查看字段统计信息SQL:

SELECT column_name, num_distinct,num_nulls, num_buckets,
(select count(1) from crm_interceptor_log) row_count
FROM DBA_TAB_COL_STATISTICS  
WHERE table_name =UPPER('crm_interceptor_log') 
AND column_name =UPPER( 'log_time') and rownum<2;

查询结果:

这里写图片描述

通过NULL值和DISTINCT值数量给出索引优化建议。