13: reporting_param_value VARCHAR2(10); -- reporting mode param value
14: tmp_buf VARCHAR2(32767);
15:
16: BEGIN
17: dbms_lob.createtemporary(feature_info, TRUE);
18:
19: select ksppstvl
20: into adaptive_plan_param
21: from x$ksppi x, x$ksppcv y where (x.indx = y.indx) and
56:
57: tmp_buf := 'Total number of queries: ' || num_all_queries ||
58: NEW_LINE ;
59:
60: dbms_lob.writeappend(feature_info, length(tmp_buf), tmp_buf);
61:
62: tmp_buf := 'Number of queries with an adaptive plan: ' ||
63: num_adaptive_queries ||
64: NEW_LINE ;
62: tmp_buf := 'Number of queries with an adaptive plan: ' ||
63: num_adaptive_queries ||
64: NEW_LINE ;
65:
66: dbms_lob.writeappend(feature_info, length(tmp_buf), tmp_buf);
67:
68: tmp_buf := 'Percentage of queries with an adaptive plan: ' ||
69: 100*num_adaptive_queries/num_all_queries ||
70: NEW_LINE ;
68: tmp_buf := 'Percentage of queries with an adaptive plan: ' ||
69: 100*num_adaptive_queries/num_all_queries ||
70: NEW_LINE ;
71:
72: dbms_lob.writeappend(feature_info, length(tmp_buf), tmp_buf);
73:
74: tmp_buf := 'Are the queries running in reporting mode ? : ' ||
75: reporting_param_value ||
76: NEW_LINE ;
74: tmp_buf := 'Are the queries running in reporting mode ? : ' ||
75: reporting_param_value ||
76: NEW_LINE ;
77:
78: dbms_lob.writeappend(feature_info, length(tmp_buf), tmp_buf);
79:
80: END dbms_feature_adaptive_plans;