其他分享
首页 > 其他分享> > 1.更改统一审计AUD$UNIFIED 分区为1天

1.更改统一审计AUD$UNIFIED 分区为1天

作者:互联网

统计审计基表AUD$UNIFIED ,不允许直接更改,且默认是按月分区。 通过以下 DBMS_AUDIT_MGMT 更改分区为1天  
BEGIN
  DBMS_AUDIT_MGMT.ALTER_PARTITION_INTERVAL(
    interval_number       => 1,
    interval_frequency    => 'DAY');
  END;
/

 

SQL> select table_name,partition_name,INTERVAL,HIGH_VALUE,HIGH_VALUE_LENGTH from dba_tab_partitions where table_name='AUD$UNIFIED';

TABLE_NAME                     PARTITION_NAME                 INT HIGH_VALUE                               HIGH_VALUE_LENGTH
------------------------------ ------------------------------ --- ---------------------------------------- -----------------
AUD$UNIFIED                    SYS_P306                       NO  TIMESTAMP' 2017-09-01 00:00:00'                         31


SYS@ORCLCDB>col owner  for a20  
SYS@ORCLCDB>col INTERVAL  for a50
SYS@ORCLCDB>select owner,table_name,interval,partitioning_type,partition_count,def_tablespace_name from dba_part_Tables where owner='AUDSYS';

OWNER                TABLE_NAME           INTERVAL                                           PARTITIONING_TYPE  PARTITION_COUNT DEF_TABLESPACE_NAME
-------------------- -------------------- -------------------------------------------------- ------------------ --------------- ------------------------------------------------------------
AUDSYS               AUD$UNIFIED          NUMTODSINTERVAL(1, 'DAY')         

  

 
       

标签:UNIFIED,NAME,分区,INTERVAL,VALUE,name,AUD
来源: https://www.cnblogs.com/cqdba/p/13258867.html