alter table scott.emp add supplemental log group gg_feed (feed_id) always;
To reverse:
alter table scott.emp drop supplemental log group gg_feed;
Minimalistic Oracle contains a collection of practical examples from my encounters with Oracle technologies. When relevant, I also write about other technologies, like Linux or PostgreSQL. Many of the posts starts with "how to" since they derive directly from my own personal experience. My goal is to provide simple examples, so that they can be easily adapted to other situations.
alter table scott.emp add supplemental log group gg_feed (feed_id) always;
alter table scott.emp drop supplemental log group gg_feed;
PASSWORD_VERSIONS | 10G 11G 12C |
---|
SQLNET.ALLOWED_LOGON_VERSION_SERVER=11
SQLNET.ALLOWED_LOGON_VERSION_SERVER=12
PASSWORD_VERSIONS | 11G 12C |
---|
set lines 200 col owner format a30 col "GB" format 999999 SELECT s.owner,sum(s.bytes/1024/1024/1024) "GB" FROM dba_segments s join dba_users u on (s.owner = u.username) where u.oracle_maintained = 'N' group by owner ORDER BY 2 desc;
OWNER GB ------------------------------ ------- USER1 19577 USER2 6144 USER3 2306
CREATE TABLE TEST_TABLE1 ( col1 NUMBER(38), col2 NUMBER(38), col3 DATE ) NOCOMPRESS TABLESPACE USERS ILM ADD POLICY ROW STORE COMPRESS ADVANCED ROW AFTER 1 DAY OF NO ACCESS;
ORA-38338: incorrect ILM policy scope |
ILM ADD POLICY ROW STORE COMPRESS ADVANCED ROW AFTER X DAY OF NO MODIFICATION;
$ORACLE_HOME/oui/bin/runInstaller -silent -deinstall REMOVE_HOMES={"/u01/oracle/product/11204"}
echo "alter system reset \"_upgrade_optim\" scope=spfile SID='*';" | sqlplus / as sysdba echo "alter system reset \"_upgrade_capture_noops\" scope=spfile SID='*';" | sqlplus / as sysdba
exec dbms_sqltune.create_sqlset(sqlset_name=>'mysts');
DECLARE my_cur dbms_sqltune.sqlset_cursor; BEGIN OPEN my_cur FOR SELECT VALUE(x) FROM TABLE( dbms_sqltune.select_workload_repository(begin_snap=>5840, end_snap=>5841, basic_filter=>'sql_id = ''45wmakdh9ak9s''')) x; dbms_sqltune.load_sqlset(sqlset_name => 'mysts', populate_cursor => my_cur); END; /
select sqlset_name, sql_id, plan_timestamp, parsing_schema_name "schema", plan_hash_value,round(elapsed_time/1000000) "duration in seconds", cpu_time, buffer_gets, disk_reads, executions from dba_sqlset_statements where sqlset_name = 'mysts' ;
SQLSET_NAME | SQL_ID | PLAN_TIMESTAMP | schema | PLAN_HASH_VALUE | duration in seconds | CPU_TIME | BUFFER_GETS | DISK_READS | EXECUTIONS |
---|---|---|---|---|---|---|---|---|---|
mysts | 45wmakdh9ak9s | 11.09.2018 15:22:13 | SH | 3827183161 | 0 | 0 | 0 | 0 | 0 |
mysts | 45wmakdh9ak9s | 06.09.2018 16:45:26 | SH | 4026264003 | 579 | 85550842 | 24062750 | 101808 | 3278857 |
VARIABLE cnt NUMBER EXECUTE :cnt := DBMS_SPM.LOAD_PLANS_FROM_SQLSET( - sqlset_name=>'mysts', basic_filter=>'plan_hash_value=3827183161', sqlset_owner=>'SYS'); print :cnt;