{"id":1301,"date":"2016-03-22T07:21:40","date_gmt":"2016-03-22T07:21:40","guid":{"rendered":"http:\/\/haisins.epac.to\/wordpress\/?p=1301"},"modified":"2016-03-22T07:21:40","modified_gmt":"2016-03-22T07:21:40","slug":"analyze-%ec%99%80-dbmsstats-%ed%86%b5%ea%b3%84-%ec%a0%95%eb%b3%b4-%ec%88%98%ec%a7%91-%ec%9d%98-%ec%b0%a8%ec%9d%b4","status":"publish","type":"post","link":"https:\/\/haisins.synology.me\/wordpress\/?p=1301","title":{"rendered":"Analyze \uc640 DBMS_STATS \ud1b5\uacc4 \uc815\ubcf4 \uc218\uc9d1 \uc758 \ucc28\uc774"},"content":{"rendered":"<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">&nbsp;<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">&nbsp;<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">&nbsp;Analyze\ub294 Serial Statistics Gathering \uae30\ub2a5 , DBMS_STATS\uc740 Parallel Gathering \uae30\ub2a5<\/span><\/p>\n<p><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">1.&nbsp;Analyze\ub294 \ud30c\ud2f0\uc158\uc758 \ud1b5\uacc4\uc815\ubcf4\ub97c \uac01 \ud30c\ud2f0\uc158 \ud14c\uc774\ube14\uacfc \uc778\ub371\uc2a4\uc5d0 \ub300\ud574\uc11c \uc218\uc9d1\ud558\uace0, Global Statistics\ub294&nbsp;<\/span><span style=\"line-height: 1.5; font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">\ud30c\ud2f0\uc158 \uc815\ubcf4\ub97c \uac00\uc9c0\uace0 \uacc4\uc0b0\ud558\ubbc0\ub85c, \ube44\uc815\ud655\ud560 \uc218 \uc788\ub2e4.&nbsp;<\/span><span style=\"line-height: 1.5; font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">\uadf8\ub7ec\ubbc0\ub85c \ud30c\ud2f0\uc158 \ub610\ub294 \uc11c\ube0c\ud30c\ud2f0\uc158\uc774 \uc788\ub294 \uac1d\uccb4\uc5d0\ub294 DBMS_STATS\uc744 \uc0ac\uc6a9 \ud574\uc57c \ud568.&nbsp;<\/span><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">2.&nbsp;DBMS_STATS\uc740 \uc804\uccb4 \ud074\ub7ec\uc2a4\ud130\uc5d0 \ub300\ud574\uc11c\ub294 \ud1b5\uacc4\uc815\ubcf4\ub97c \uc218\uc9d1\ud558\uc9c0 \uc54a\uc73c\ubbc0\ub85c Analyze\ub97c \uc0ac\uc6a9<\/span><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">3. DBMS_STATS\uc740 CBO\uc640 \uad00\ub828\ub41c \ud1b5\uacc4\uc815\ubcf4\ub9cc\uc744 \uc218\uc9d1\ud55c\ub2e4. \ud14c\uc774\ube14\uc758 EMPTY_BLOCKS, AVG_SPACE,CHAIN_CNT \ub4f1\uc740&nbsp;<\/span><span style=\"line-height: 1.5; font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">\uc218\uc9d1\ub418\uc9c0 \uc54a\ub294\ub2e4.&nbsp;<\/span><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">4. DBMS_STATS\uc740 \uc0ac\uc6a9\uc790\uac00 \uc9c0\uc815\ud55c \ud1b5\uacc4\uc815\ubcf4 \ud14c\uc774\ube14\uc5d0 \uc218\uc9d1\ub41c \ud1b5\uacc4\uc815\ubcf4\ub97c \uc800\uc7a5\ud560\uc218\uc788\uace0, \ub515\uc154\ub108\ub9ac\ub85c \uac01 \uce7c\ub7fc, \ud14c\uc774\ube14,&nbsp;<\/span><span style=\"line-height: 1.5; font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">\uc778\ub371\uc2a4, \uc2a4\ud0a4\ub9c8\ub4f1\uc744 \ubc18\uc601\ud560\uc218\uc788\ub2e4.&nbsp;<\/span><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">5. DBMS_STATS\uc740 IMPORT\/EXPORT \uae30\ub2a5 \ubc0f \ucd94\uac00\uc801\uc778 \uae30\ub2a5\uc774 \ub9ce\ub2e4.&nbsp;<\/span><span style=\"line-height: 1.5; font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">\uc774 \uae30\ub2a5 \uc744 \uc774\uc6a9\ud558\uc5ec \uc6b4\uc601 DB\uc758 \ud1b5\uacc4\uc815\ubcf4\ub97c \uac1c\ubc1c\uc7a5\ube44\uc758 \ud1b5\uacc4\uc815\ubcf4\ub85c \ubcf5\uc0ac\ud560 \uc218 \uc788\uc73c\ubbc0\ub85c \uac1c\ubc1c\uc7a5\ube44\uc758 \ud50c\ub79c\uc744&nbsp;<\/span><span style=\"line-height: 1.5; font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">\uc6b4\uc601\uc7a5\ube44\uc640 \uac19\uac8c \ub9cc\ub4e4 \uc218 \uc788\ub2e4.&nbsp;<\/span><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">\ub2e4\uc74c\uc740 Analyze \uba85\ub839\uc5b4\uc5d0\ub9cc \uc788\ub294 \uae30\ub2a5\uc774\ub2e4.&nbsp;<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">Structural Integrity Check \uae30\ub2a5&nbsp;<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">analyze { index\/table\/cluster } (schema.){ index\/table\/cluster } validate structure (cascade) (into schema.table);&nbsp;<\/span><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">Chained Rows \uc218\uc9d1 \uae30\ub2a5&nbsp;<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">ANALYZE TABLE order_hist LIST CHAINED ROWS INTO ;<\/span><\/p>\n<p><\/p>\n<p><span style=\"line-height: 1.5; font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-<\/span><\/p>\n<p><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 10pt;\">\uacb0\ub860: analyze \uc9c1\ud6c4 dbms_stats\ud558\uba74 admin stat\uacfc optimizer stat\uc774 \uc81c\ub300\ub85c merge\ub428.<\/span><\/p>\n<p><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">drop table &nbsp;blueone;<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">create table &nbsp;blueone<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">pctfree 5<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">storage( initial 1M next 1M pctincrease 0 )<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">partition by range (object_type)<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&nbsp; &nbsp; &nbsp; &nbsp;(partition &nbsp;pt &nbsp;values less than (&#8216;U&#8217;),<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&nbsp; &nbsp; &nbsp; &nbsp; partition &nbsp;pz &nbsp;values less than (maxvalue)<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&nbsp; &nbsp; &nbsp; &nbsp;)<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">nologging<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">as<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">select *<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">from &nbsp;all_objects<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">where rownum &lt;= 10000<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">;<\/span><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">update &nbsp;blueone<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&nbsp; &nbsp;set &nbsp;SUBOBJECT_NAME = rpad(&#8216; &#8216;,30)<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">;<\/span><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">commit;<\/span><\/p>\n<p><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">analyze table blueone compute statistics;<\/span><\/p>\n<p><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">col &nbsp;&#8220;GLOBAL_STATS&#8221; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;form a6 &nbsp; &nbsp; &nbsp; &nbsp;heading Global_|Stats<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">col &nbsp;&#8220;LAST_ANALYZED&#8221; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; form a20 &nbsp; &nbsp; &nbsp; heading Last_Analyzed<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">col &nbsp;&#8220;TABLE_NAME&#8221; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;form a10 &nbsp; &nbsp; &nbsp; heading Table_Name<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">col &nbsp;&#8220;USER_STATS&#8221; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;form a6 &nbsp; &nbsp; &nbsp; &nbsp;heading User_|Stats<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">col &nbsp;&#8220;AVG_ROW_LEN&#8221; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; form 9999 &nbsp; &nbsp; &nbsp;heading Avg_|Row_|Len<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">col &nbsp;&#8220;AVG_SPACE&#8221; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; form 9999 &nbsp; &nbsp; &nbsp;heading Avg_|Space<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">col &nbsp;&#8220;AVG_SPACE_FREELIST_BLOCKS&#8221; form 9999 &nbsp; &nbsp; &nbsp;heading Avg_|Space_|Freelist_|Blocks<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">col &nbsp;&#8220;BLOCKS&#8221; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;form 99999 &nbsp; &nbsp; heading Blocks<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">col &nbsp;&#8220;CHAIN_CNT&#8221; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; form 9999 &nbsp; &nbsp; &nbsp;heading Chain_|Cnt<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">col &nbsp;&#8220;EMPTY_BLOCKS&#8221; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;form 9999 &nbsp; &nbsp; &nbsp;heading Empty_|Blocks<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">col &nbsp;&#8220;NUM_FREELIST_BLOCKS&#8221; &nbsp; &nbsp; &nbsp; form 9999 &nbsp; &nbsp; &nbsp;heading Num_|Freelist_|Blocks<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">col &nbsp;&#8220;NUM_ROWS&#8221; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;form 99999999 &nbsp;heading Num_|Rows<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">col &nbsp;&#8220;SAMPLE_SIZE&#8221; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; form 99999999 &nbsp;heading Sample_|Size<\/span><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">select &nbsp;table_name, NUM_ROWS, BLOCKS, EMPTY_BLOCKS, AVG_SPACE, CHAIN_CNT, AVG_ROW_LEN, SAMPLE_SIZE, LAST_ANALYZED, AVG_SPACE_FREELIST_BLOCKS, NUM_FREELIST_BLOCKS, GLOBAL_STATS &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">from &nbsp;all_tables<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">where &nbsp;owner = USER<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&nbsp; and &nbsp;table_name = &#8216;blueone&#8217;<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&#8212;&#8212;&#8212;&#8212;<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">union all<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&#8212;&#8212;&#8212;&#8212;<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">select &nbsp;partition_name, NUM_ROWS, BLOCKS, EMPTY_BLOCKS, AVG_SPACE, CHAIN_CNT, AVG_ROW_LEN, SAMPLE_SIZE, LAST_ANALYZED, null, null, null<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">from &nbsp;all_tab_partitions<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">where &nbsp;table_owner = USER<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&nbsp; and &nbsp;table_name = &#8216;blueone&#8217;<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">;<\/span><\/p>\n<p><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">\/*<\/span><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Avg_<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Avg_ &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Space_ &nbsp; &nbsp; &nbsp;Num_<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Num_ &nbsp; &nbsp; &nbsp; &nbsp;Empty_ &nbsp;Avg_ Chain_ &nbsp;Row_ &nbsp; Sample_ &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Freelist_ Freelist_ Global<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">Table_Name &nbsp; &nbsp; &nbsp;Rows Blocks Blocks Space &nbsp; &nbsp;Cnt &nbsp; Len &nbsp; &nbsp; &nbsp;Size Last_Analyzed &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Blocks &nbsp; &nbsp;Blocks Stats<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&#8212;&#8212;&#8212;- &#8212;&#8212;&#8212; &#8212;&#8212; &#8212;&#8212; &#8212;&#8211; &#8212;&#8212; &#8212;&#8211; &#8212;&#8212;&#8212; &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211; &#8212;&#8212;&#8212; &#8212;&#8212;&#8212; &#8212;&#8212;<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">blueone &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 10000 &nbsp; &nbsp;236 &nbsp; &nbsp;148 &nbsp;1940 &nbsp; &nbsp; &nbsp;0 &nbsp; 125 &nbsp; &nbsp; &nbsp; &nbsp; 0 03\/08\/26-16:12:11 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;0 &nbsp; &nbsp; &nbsp; &nbsp; 0 NO<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">PT &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;7519 &nbsp; &nbsp;189 &nbsp; &nbsp; 67 &nbsp;2273 &nbsp; 1557 &nbsp; 129 &nbsp; &nbsp; &nbsp;7519 03\/08\/26-16:12:10<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">PZ &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;2481 &nbsp; &nbsp; 47 &nbsp; &nbsp; 81 &nbsp; 934 &nbsp; &nbsp;619 &nbsp; 113 &nbsp; &nbsp; &nbsp;2481 03\/08\/26-16:12:11<\/span><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">*\/<\/span><\/p>\n<p><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">drop table blueone;<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&#8212; recreate blueone<\/span><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">declare BEGIN dbms_stats.gather_table_stats(ownname=&gt;USER, tabname=&gt;&#8217;blueone&#8217; ); END;<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">\/<\/span><\/p>\n<p><\/p>\n<p><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Avg_<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Avg_ &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Space_ &nbsp; &nbsp; &nbsp;Num_<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Num_ &nbsp; &nbsp; &nbsp; &nbsp;Empty_ &nbsp;Avg_ Chain_ &nbsp;Row_ &nbsp; Sample_ &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Freelist_ Freelist_ Global<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">Table_Name &nbsp; &nbsp; &nbsp;Rows Blocks Blocks Space &nbsp; &nbsp;Cnt &nbsp; Len &nbsp; &nbsp; &nbsp;Size Last_Analyzed &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Blocks &nbsp; &nbsp;Blocks Stats<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&#8212;&#8212;&#8212;- &#8212;&#8212;&#8212; &#8212;&#8212; &#8212;&#8212; &#8212;&#8211; &#8212;&#8212; &#8212;&#8211; &#8212;&#8212;&#8212; &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211; &#8212;&#8212;&#8212; &#8212;&#8212;&#8212; &#8212;&#8212;<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">blueone &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 10000 &nbsp; &nbsp;236 &nbsp; &nbsp; &nbsp;0 &nbsp; &nbsp; 0 &nbsp; &nbsp; &nbsp;0 &nbsp; 120 &nbsp; &nbsp; 10000 03\/08\/26-16:20:07 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;0 &nbsp; &nbsp; &nbsp; &nbsp; 0 YES<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">PT &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;7519 &nbsp; &nbsp;189 &nbsp; &nbsp; &nbsp;0 &nbsp; &nbsp; 0 &nbsp; &nbsp; &nbsp;0 &nbsp; 124 &nbsp; &nbsp; &nbsp;7519 03\/08\/26-16:20:06<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">PZ &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;2481 &nbsp; &nbsp; 47 &nbsp; &nbsp; &nbsp;0 &nbsp; &nbsp; 0 &nbsp; &nbsp; &nbsp;0 &nbsp; 107 &nbsp; &nbsp; &nbsp;2481 03\/08\/26-16:20:06<\/span><\/p>\n<p><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">analyze table blueone delete statistics;<\/span><\/p>\n<p><\/p>\n<p><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&lt;\ucc28\uc774\uc810&gt;<\/span><\/p>\n<p><\/p>\n<p><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; NUM_ROWS &nbsp; &nbsp; BLOCKS EMPTY_BLOCKS &nbsp;AVG_SPACE &nbsp;CHAIN_CNT AVG_ROW_LEN SAMPLE_SIZE LAST_ANALYZED<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8212; &#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8211; &#8212;&#8212;&#8212;&#8211; &#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">ANALYZE &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;27263 &nbsp; &nbsp; &nbsp; &nbsp;512 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;0 &nbsp; &nbsp; &nbsp; &nbsp;642 &nbsp; &nbsp; &nbsp; 4444 &nbsp; &nbsp; &nbsp; &nbsp; 127 &nbsp; &nbsp; &nbsp; 27263 03\/08\/26-15:55:32<\/span><\/p>\n<p><span style=\"font-family: Gulim, \uad74\ub9bc, AppleGothic, sans-serif; font-size: 8pt;\">DBMS_STATS &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 27263 &nbsp; &nbsp; &nbsp; &nbsp;512 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;0 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;0 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;0 &nbsp; &nbsp; &nbsp; &nbsp; 123 &nbsp; &nbsp; &nbsp; 27263 03\/08\/26-15:56:13<\/span><\/p>\n<p><\/p>\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>&nbsp; &nbsp; &nbsp;Analyze\ub294 Serial Statistics Gathering \uae30\ub2a5 , DBMS_STATS\uc740 Parallel Gathering \uae30\ub2a5 1.&nbsp;Analyze\ub294 \ud30c\ud2f0\uc158\uc758 \ud1b5\uacc4\uc815\ubcf4\ub97c \uac01 \ud30c\ud2f0\uc158 \ud14c\uc774\ube14\uacfc \uc778\ub371\uc2a4\uc5d0 \ub300\ud574\uc11c \uc218\uc9d1\ud558\uace0, Global Statistics\ub294&nbsp;\ud30c\ud2f0\uc158 \uc815\ubcf4\ub97c \uac00\uc9c0\uace0 \uacc4\uc0b0\ud558\ubbc0\ub85c, \ube44\uc815\ud655\ud560 \uc218 \uc788\ub2e4.&nbsp;\uadf8\ub7ec\ubbc0\ub85c \ud30c\ud2f0\uc158 \ub610\ub294 \uc11c\ube0c\ud30c\ud2f0\uc158\uc774 \uc788\ub294 \uac1d\uccb4\uc5d0\ub294 DBMS_STATS\uc744 \uc0ac\uc6a9 \ud574\uc57c \ud568.&nbsp; 2.&nbsp;DBMS_STATS\uc740 \uc804\uccb4 \ud074\ub7ec\uc2a4\ud130\uc5d0 \ub300\ud574\uc11c\ub294 \ud1b5\uacc4\uc815\ubcf4\ub97c \uc218\uc9d1\ud558\uc9c0 \uc54a\uc73c\ubbc0\ub85c Analyze\ub97c \uc0ac\uc6a9 3. DBMS_STATS\uc740 CBO\uc640 \uad00\ub828\ub41c \ud1b5\uacc4\uc815\ubcf4\ub9cc\uc744 \uc218\uc9d1\ud55c\ub2e4. \ud14c\uc774\ube14\uc758 EMPTY_BLOCKS, [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_bbp_topic_count":0,"_bbp_reply_count":0,"_bbp_total_topic_count":0,"_bbp_total_reply_count":0,"_bbp_voice_count":0,"_bbp_anonymous_reply_count":0,"_bbp_topic_count_hidden":0,"_bbp_reply_count_hidden":0,"_bbp_forum_subforum_count":0,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"spay_email":""},"categories":[9],"tags":[326,161,134,162,726],"jetpack_featured_media_url":"","amp_enabled":true,"_links":{"self":[{"href":"https:\/\/haisins.synology.me\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/1301"}],"collection":[{"href":"https:\/\/haisins.synology.me\/wordpress\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/haisins.synology.me\/wordpress\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/haisins.synology.me\/wordpress\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/haisins.synology.me\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1301"}],"version-history":[{"count":0,"href":"https:\/\/haisins.synology.me\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/1301\/revisions"}],"wp:attachment":[{"href":"https:\/\/haisins.synology.me\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1301"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/haisins.synology.me\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1301"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/haisins.synology.me\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1301"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}