为了使基于CBO的执行计划更加准确,统计分析大数据表是数据库管理的重要部分。数据库统计分析SQL如下:
ORACLE统计分析语句
analyze table T00_TEST compute statistics ;
DB2统计分析语句
runstats on table T00_TEST t with distribution and detailed indexes shrlevel change;
为了使基于CBO的执行计划更加准确,统计分析大数据表是数据库管理的重要部分。数据库统计分析SQL如下:
ORACLE统计分析语句
analyze table T00_TEST compute statistics ;
DB2统计分析语句
runstats on table T00_TEST t with distribution and detailed indexes shrlevel change;