declare v_cnt pls_integer; begin for rec in (select distinct table_owner, table_name from dba_tab_partitions) loop execute immediate 'select count(1) from "'||rec.table_owner||'"."'||rec.table_name||'"' into v_cnt; if v_cnt > 0 then dbms_output.put_line('"'||rec.table_owner||'"."'||rec.table_name||'" - '||v_cnt); end if; end loop; end; / "SYS"."WRH$_SEG_STAT" – 3138
SQL> create table t (n number) partition by hash(n) partitions 16; create table t (n number) partition by hash(n) partitions 16 * ERROR at line 1: ORA-00439: feature not enabled: Partitioning
-- Turn ON the event to disable the partition check alter session set events '14524 trace name context forever, level 1';
SQL> connect usr/password@database Connected. SQL> alter session set events '14524 trace name context forever, level 1'; Session altered. SQL> create table t (n number) partition by hash(n) partitions 16; Table created. SQL>
alter system set events '14524 trace name context forever, level 1';
alter system set events '14524 trace name context off';
select name ,version ,detected_usages ,total_samples ,currently_used ,first_usage_date ,last_usage_date ,aux_count ,last_sample_period from dba_feature_usage_statistics where last_usage_date is not null and name like '%Part%' ; NAME VERSION DETECTED_USAGES TOTAL_SAMPLES CURRE FIRST_US LAST_USA AUX_COUNT LAST_SAMPLE_PERIOD --------------------- ----------- --------------- ------------- ----- -------- -------- - --------- ------------------ Partitioning (system) 11.2.0.3.0 1 1 TRUE 28.11.12 28.11.12 2,74 0
Source: https://habr.com/ru/post/245337/
All Articles