SlideShare a Scribd company logo
Redefining Tables Online
Without Surprises
Latin American OTN Tour – August 2017
Nelson Calero
• Database Consultant at Pythian since 2014
• Working with Oracle tools and Linux environments since 1996
• DBA Oracle (2001) & MySQL (2005)
• Co-founder and President of the Oracle user Group of Uruguay (2009)
• LAOUC Director of events (2013)
• Computer Engineer (1998)
• Oracle ACE (2014), Oracle ACE Director (2017)
• Oracle Certified Professional DBA 10g/11g/12c (2008)
• Amazon Solutions Architect – Associate since (2016)
• Oracle University Instructor (2011)
• Blogger and speaker: Oracle Open World, Collaborate, OTN Tour, Regional conferences
About me
2 © 2017 Pythian
http://www.linkedin.com/in/ncalero @ncalerouy
Pythian overview
© 2015 Pythian Confidential3
• 20 Years of data infrastructure management consulting
• 250+ Top brands
• 11800+ systems under management
• 400+ employees in 35 countries
• 10 Oracle ACEs, 4 ACED,
3 OakTable members, 2 OCM, 6 Microsoft MVPs,
1 Cloudera Champion of Big Data,
AWS Certified Solutions Architect – 2 Professional, 12 Associate
• Oracle, Microsoft, MySQL, Hadoop, Cassandra, MongoDB, and more
• Infrastructure, Cloud, DevOps, and application expertise
Online table redefinition
• Motivation
• Online DDL review
• dbms_redefinition examples
• Changes in different Oracle versions
• Known restrictions
• Problems found
• Real life usage to compress a VLDB
4 © 2017 Pythian
Motivation
• DDL operations have different optimizations to make it faster
– DDL locks are held (shared or exclusive) while operation runs
– Larger tables with some DDL that do not implement optimizations will keep locks longer
• DML automatically grab locks to keep consistency
– Row Locks (TX) and Table Locks (TX) using different modes: RS, RX, S, SRX, X
– Conflicting locks will delay running transactions
– More visible with large tables and heavy concurrency
• Some example DDLs:
– Change table columns: add/drop/modify attributes (name, datatype, length, compression, etc.)
– Move a table to a different tablespace
– Partition a non-partitioned table (and vice-versa)
– Compress an uncompressed table (and vice-versa)
– Reorganize data to change physical layout
• rows per block (PCTFREE), Ordering (clustering factor)
5 © 2017 Pythian
Optimized DDL operations - example
• Adding a column to a table:
ALTER TABLE t1 ADD C1 number;
• Metadata updated, no change made to existing rows
• Including now a default value:
ALTER TABLE t1 ADD C1 number default 1;
• Before 12c: existing rows are updated adding the new value
• Since 12c: metadata updated, no changes to existing rows
• Restrictions with LOBs, IOTs, temporary, MVs, VPD, encryption, queue
• NOT NULL instead of NULL:
ALTER TABLE t1 ADD C1 number default 1 not null ;
• Before 11g – existing rows are updated adding the new value
• Since 11g – metadata updated, no changes to existing rows
https://docs.oracle.com/database/121/SQLRF/statements_3001.htm#CIHGHAJG
http://www.oracle.com/technetwork/articles/database/ddl-optimizaton-in-odb12c-2331068.html
6 © 2017 Pythian
Example
Terminal 1:
watch -d --interval=1 "sqlplus -s / as sysdba @locks | tee -a watch.log"
Terminal 2:
- Generate DML (ex: insert a record without commit)
Terminal 3:
- Play with DDL
- Example: alter table add / drop column, index, constraints
7 © 2017 Pythian
Today’s focus
• We are looking to modify the structure of a table without blocking
other users’ transactions
– Also known as Online DDL
– Highlighted as HA features (as no application downtime is required)
• Several operations already implemented as online in Oracle if
conditions are met (details to follow)
• Some only available on Enterprise Edition (EE)
8 © 2017 Pythian
Online operations in Oracle
• Only in Enterprise Edition
– Online index rebuild – since 8i
– Online index-organized table organization (alter table move)
– Online table redefinition (dbms_redefinition) – since 9i
– Online partition/sub-partition move – since 12.1
– Online table move – since 12.2
– Online SPLIT Partition and Subpartition – since 12.2
• Restrictions apply per functionality and version
– Example: bitmaps, IOTs, Parallel DML, column datatypes
• Note the ‘online’ clause needs to be added to the SQL statement
alter index T1_IDX rebuild online;
alter table T1 move online tablespace NEW_TS;
9 © 2017 Pythian
Online DDL – poor’s man approach
- Create empty table with the changes needed
- Copy source rows to modified table
- Copy changes received since operation started
- repeat as needed (controlling amount of data moved each time)
- lock table in exclusive mode
- interchange old and new table (renaming both)
- Goal is to minimize the exclusive lock duration
- Dependent objects needs to be created manually
- Constraints, indices, triggers – pre-creating them disabled adds run-time overhead
- Names should be interchanged with original ones
• Several examples from open source databases
– pt-online-schema-change (MySQL - Percona), osc_cli (MySQL – Facebook)
– pg_repack (PostgreSQL)
10 © 2017 Pythian
Online operations in Oracle
• Obvious thing to remark: RTFM !!
– Features change in versions
– Restrictions for each operation based on structure
– Patches to fix known bugs
• Example: ALTER TABLE <table> MOVE …
– On 12.2 the ONLINE option allows DML against the <table> while it runs
• dbms_redefinition is needed before 12.2
– Indexes are marked unusable because ROWID changes
• ORA-1502 reported by queries using those indexes
– LOB columns are not moved by default
• we need to include it explicitly if we want to move them with the table
11 © 2017 Pythian
Example: moving a single partition
• In Oracle 12.1:
alter table test.T1 move partition P4 online update indexes;
• Bug 'Inconsistent Datatypes: Expected NUMBER (Doc ID 2028583.1)‘ on
12.1.0.2.170117
- needs one-off patch 20703000
• Physical attributes gets copied
- if we plan to change them, better to do it before moving:
alter table test.T1 modify default attributes STORAGE(INITIAL
1048576 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645);
alter table test.T1 move partition P4 online update indexes;
• Pre-12.1: only using dbms_redefinition
12 © 2017 Pythian
dbms_redefinition
• Available since version 9i to allow online DDL
• A snapshot log is automatically created saving changes while data is copied
• Resync as many times as needed (good to resume failures)
• Minimum time needed for the final step to rename tables
• Needs 2x original space – a temporal (interim) table is used
– Don’t forget increasing redolog activity, archivelog space and standby transport
• Simplified in 12c for some use cases
– One procedure does all the work, but is less flexible
13 © 2017 Pythian
dbms_redefinition - workflow
14 © 2017 Pythian
Original
Index1
Index2
dbms_redefinition - workflow
15 © 2017 Pythian
Original
Index1
Index2
Interim
Index1$
1 create interim table
dbms_redefinition - workflow
16 © 2017 Pythian
Original
Index1
Index2
Interim
Index1$
2 Start redefinition
MLOG
dbms_redefinition - workflow
17 © 2017 Pythian
Original
Index1
Index2
Interim
Index1$
MLOG 3 Sync redefinition
dbms_redefinition - workflow
18 © 2017 Pythian
Original
Index1
Index2
Interim
Index1$
Index2$
MLOG 4 Copy dependent objects
dbms_redefinition - workflow
19 © 2017 Pythian
Original
Index1
Index2
Interim
Index1$
Index2$
MLOG
5 Finish redefinition (1/2)
dbms_redefinition - workflow
20 © 2017 Pythian
Interim
Index1$
Index2$
Original
Index1
Index2
5 Finish redefinition (2/2)
MLOG
dbms_redefinition – complete workflow
21 © 2017 Pythian
Original table
Index1
Index2
Interim table
Index1
Index2
1
2
create interim table
Start redefinition
MLOG
3
Sync redefinition
5 Finish redefinition
4
Copy dependent
objects
dbms_redefinition – 12c simple usage
DBMS_REDEFINITION.REDEF_TABLE (
uname IN VARCHAR2,
tname IN VARCHAR2,
table_compression_type IN VARCHAR2 := NULL,
table_part_tablespace IN VARCHAR2 := NULL,
index_key_compression_type IN VARCHAR2 := NULL,
index_tablespace IN VARCHAR2 := NULL,
lob_compression_type IN VARCHAR2 := NULL,
lob_tablespace IN VARCHAR2 := NULL,
lob_store_as IN VARCHAR2 := NULL)
We can combine all parameters in a single execution to:
 compress table and all LOBs
 change tablespace for table (or all partitions), all indexes and all LOBs
 change LOB to store as SECUREFILE or BASICFILE
22 © 2017 Pythian
dbms_redefinition – 12c example
Moving an entire table changing table, indexes and LOBs attributes:
begin
DBMS_REDEFINITION.REDEF_TABLE (
uname => 'TEST',
tname => 'T1',
table_compression_type => 'ROW STORE COMPRESS ADVANCED',
table_part_tablespace => 'TEST_COMP',
index_key_compression_type => 'COMPRESS ADVANCED LOW',
index_tablespace => 'TEST_IDX_COMP',
lob_compression_type => 'COMPRESS HIGH',
lob_tablespace => 'TEST_COMP',
lob_store_as => 'SECUREFILE');
end;
NOTE: Table and index owner (TEST) needs quota privilege on new tablespace TEST_COMP.
23 © 2017 Pythian
dbms_redefinition – 12c example
Demo – example1.sql
Compressing a partitioned table, doing some validations and
discovering some issues:
- hidden columns created when using ROWID
- NOVALIDATE constraints after redefinition (BUG 4396234)
- see concurrency effect
NOTE: All examples used in this presentation are in dropbox
24 © 2017 Pythian
dbms_redefinition - restrictions
• Same schema
• LONG and LONG RAW columns cannot be redefined
– cannot be moved manually either (alter table .. move)
– LONG columns must be converted to CLOBS
– LONG RAW columns must be converted to BLOBS
– needs application testing
• NOTE: BFILE columns can be redefined online starting on 12.2
• Known bugs with one-off patch available (11.2.0.4 example):
- 18889295 - ORA-600 [4511] kdbchk: row locked by non-existent transaction on OLTP
compressed table
- 21887221 - Primary Key Constraint index changes after redefinition when a primary key index is
a subset of another normal index being present on the same table
25 © 2017 Pythian
dbms_redefinition – long approach
1) Manually create the interim table with the changes we want
2) Validates if table can be redefined online
DBMS_REDEFINITION.can_redef_table (owner, seg, flag, part);
3) Start Redefinition
DBMS_REDEFINITION.start_redef_table (owner, seg, interim, part);
4) Apply changes captured while previous step ran
DBMS_REDEFINITION.sync_interim_table (owner, seg, interim);
5) Copy dependent objects
DBMS_REDEFINITION.copy_table_dependents (owner, seg, interim, errors);
6) Finish – exchange table names (p_seg and p_int_tab)
DBMS_REDEFINITION.finish_redef_table (owner, seg, interim, part);
26 © 2017 Pythian
dbms_redefinition – short or long usage?
Old approach (with more steps) needed in 12c for:
• structural changes
• moving only some partitions/lobs/indexes (not all)
• Not recommended for structural changes
start_redef_table offers some extra features:
– Reorder rows using order by clause (orderby_cols parameter)
– Copy only some columns, or create new combining functions to existing
ones (col_mapping parameter)
NOTE: data is copied without generating UNDO (APPEND hint is used in the
INSERT statement)
27 © 2017 Pythian
dbms_redefinition – COPY_TABLE_DEPENDENTS
• Clone indexes, privileges, triggers, constraints and statistics
• Triggers and referential integrity constraints are created disabled, enabled
automatically after redefinition completes
• All cloned objects are renamed to the original names when redefinition
completes – interim table is the original table at that point, having internal
names for cloned objects
History:
• Added in 10g
• Since 11.1 dependent objects are not invalidated (PL/SQL, views,
synonyms etc.)
28 © 2017 Pythian
dbms_redefinition – new in 12.2
• V$ONLINE_REDEF
Progress reported by START_REDEF_TABLE and COPY_TABLE_DEPENDENTS
• Restarting redefinition after failures
DBA_REDEFINITION_STATUS view includes new columns to identify the object and error, allowing to resolve
error and resume failed operation
Example: datafile full when executing SYNC
• Rolling back redefinition after it was completed
New parameter ENABLE_ROLLBACK in START_REDEF_TABLE
New procedures ABORT_ROLLBACK and ROLLBACK
After completing a redefinition with rollback enabled, MLOG is not dropped. We can SYNC after that to keep
old source table (now interim) updated, until we decide to rollback or abort it
• BFILE columns support
• SYNC_INTERIM_TABLE can incremental refresh dependent MVs on the interim table
29 © 2017 Pythian
dbms_redefinition – troubleshooting
• Errors are recorded in dba_redefinition_errors
– From redefinition step (first) and copy dependent objects procedure
– Nothing from compact 12c REDEF_TABLE – it works or aborts
• Manual procedure allows to fix errors and resume
• To cancel a non completed redef
DBMS_REDEFINITION.ABORT_REDEF_TABLE
• If in doubt: SQL trace of the session running redefinition
30 © 2017 Pythian
dbms_redefinition – more examples
Demo
– example2.sql : 11g approach to move a single partition
- Using DBMS_METADATA.GET_DDL to generate interim table
- See concurrency effect and data movement
– example3.sql – redefining a table having hidden columns
31 © 2017 Pythian
dbms_redefinition – troubleshooting examples
Demo
– example4.sql: solving errors when copying constraints
• Interim table have NOT NULL columns and we try to copy
constraints using copy_table_dependents
• Side effect after resolving it with final table structure
– example5.sql: solving error when copying index
• Source table has a bitmap index, using copy_table_dependents
gives error
• Using register_dependent_object to redefine table
32 © 2017 Pythian
dbms_redefinition – Summary
• Redefine using PK if available
– Avoid hidden column added when using ROWID (known issue as per MOS 459762.1)
• When creating Interim table, columns should be nullable to avoid errors when copying dependent
– Use dbms_metadata.get_ddl to automate it
• NOT NULL constraints are left NOVALIDATE after clone
– Bug:4396234 - we need to modify them after redefinition completes
• To exclude a particular objects from COPY_TABLE_DEPENDENTS:
– Use REGISTER_DEPENDENT_OBJECT before
– object must be manually pre-created, and will be renamed at the end
• Optimizer stats can be copied – check if that makes sense for you
– Clustering factor change - data is defragmented, orderby clause can be used, pctfree can change, etc.
33 © 2017 Pythian
Real life approach to compress VLDB
Procedure outline
– By object or tablespace approach?
– Identify objects to exclude (matching known restrictions)
• both for dbms_redefinition and compression
– Plan space needs – 2x for each table (and index)
– Automate whenever possible – dropping objects too?
– Able to split indexes from table maintenance?
• Needs application usage planning, as it could affect SQL using them
Facts
– 30Tb database, 350 tablespaces, 2000 datafiles
– Combination of all datatypes and structures
• IOTs, partitioned, basicfile LOBs, LONG
– More than 24hs needed to redefine 1Tb tables
– Different space savings found – floor around 2x
34 © 2017 Pythian
THANK YOU
Questions?
35
calero@pythian.com
@ncalerouy
http://www.linkedin.com/in/ncalero
© 2017 Pythian
References - documentation
• DBMS_REDEFINITION - 12.2 Database PL/SQL Packages and Types Reference
https://docs.oracle.com/database/122/ARPLS/DBMS_REDEFINITION.htm#ARPLS042
• Automatic Locks in DML Operations - 12.2 Database SQL Language Reference
https://docs.oracle.com/database/122/SQLRF/Automatic-Locks-in-DML-Operations.htm#SQLRF55502
• Managing Tables - 12.2 Database Administrator’s Guide
https://docs.oracle.com/database/122/ADMIN/managing-tables.htm
• All examples in this presentation are in dropbox, http://bit.ly/2w71qxb
36 © 2017 Pythian
dbms_redefinition – common issues
1) ORA-12093: invalid interim table "OWNER"."TABLE"
• Intermediate table named in the “redef_table” is not created yet
2) ORA-12089: cannot online redefine table "OWNER"."TABLE" with no primary key
• A table with no PK was tried to be redefined without using the ROWID option
3) ORA-23539: table "OWNER"."NAME" currently being redefined
• Table redefinition finished with errors and a new “redef_table” was run
If data was already copied and failure was during copy dependents steps, we don’t need to
drop the table and start again - we can keep the already copied data, resolve errors, sync and
repeat copy dependants.
37 © 2017 Pythian
dbms_redefinition – common issues (2)
4) ORA-00997: illegal use of LONG datatype
• Columns LONG, LONG RAW and BFILE cannot be redefined.
https://docs.oracle.com/cd/B28359_01/server.111/b28310/tables007.htm#ADMIN11674
5) ORA-23541: tables do not match tables used while defining the redefinition
• When COPY_TABLE_DEPENDENTS is used for a single partition, it tries to copy
partitioned table objects when target is not partitioned and only an exchange
partition will be executed
Solution:
• copying dependents should not be used when moving single partitions
38 © 2017 Pythian
dbms_redefinition – unexpected issues
6) ORA-25965: fact table must be included in the from clause
• This is because index DDL generated by redefinition contains reference to
source table without being changed to the new name
SQL reported in DBA_REDEFINITION_ERRORS.DDL_TXT:
CREATE BITMAP INDEX "TEST"."TMP$$_IDX_JOIN0"
ON "TEST"."T3_RDEF" ("T97912"."CODE")
FROM "TEST"."T2" "T97912", "TEST"."T3" "T97911"
WHERE "T97911"."ID"="T97912"."BUCK_ID“
Solution:
• manually create index with the correct name before starting
• exclude index from redefinition using REGISTER_DEPENDENT_OBJECT
39 © 2017 Pythian
dbms_redefinition – unexpected issues (2)
7) ORA-14024: number of partitions of LOCAL index must equal that of the underlying table
• Interim table was created using dbms_metadata, but it got table and index creation with less partitions than the
existing one (not updated with new partitions added)
Solution:
• Manually adjust interim table creation SQL adding missing partitions from existing index
8) ORA-01442: column to be modified to NOT NULL is already NOT NULL
• Intermediate table was created with not null columns
Solution:
• Remove not null constraint from interim table and retry
desc will show table not having not null constraints, but the check constraint is there and enabled
1) drop check constraints on interim tables
2) resync, retry copy dependent and finish redefinition
3) enable validate check constraints
Caused by a known bug:4396234 ET10.2OREDEF: NULLABLE COL OF *_TAB_COLUMNS TABLE NOT UPDATED
AFTER ONLINE REDEF
40 © 2017 Pythian

More Related Content

What's hot

Oracle Database Performance Tuning Advanced Features and Best Practices for DBAs
Oracle Database Performance Tuning Advanced Features and Best Practices for DBAsOracle Database Performance Tuning Advanced Features and Best Practices for DBAs
Oracle Database Performance Tuning Advanced Features and Best Practices for DBAs
Zohar Elkayam
 
Oracle RAC 12c Practical Performance Management and Tuning OOW13 [CON8825]
Oracle RAC 12c Practical Performance Management and Tuning OOW13 [CON8825]Oracle RAC 12c Practical Performance Management and Tuning OOW13 [CON8825]
Oracle RAC 12c Practical Performance Management and Tuning OOW13 [CON8825]
Markus Michalewicz
 
Tanel Poder - Scripts and Tools short
Tanel Poder - Scripts and Tools shortTanel Poder - Scripts and Tools short
Tanel Poder - Scripts and Tools short
Tanel Poder
 
SQL Tuning 101
SQL Tuning 101SQL Tuning 101
SQL Tuning 101
Carlos Sierra
 
Best Practices for the Most Impactful Oracle Database 18c and 19c Features
Best Practices for the Most Impactful Oracle Database 18c and 19c FeaturesBest Practices for the Most Impactful Oracle Database 18c and 19c Features
Best Practices for the Most Impactful Oracle Database 18c and 19c Features
Markus Michalewicz
 
Oracle GoldenGate Performance Tuning
Oracle GoldenGate Performance TuningOracle GoldenGate Performance Tuning
Oracle GoldenGate Performance Tuning
Bobby Curtis
 
HBase in Practice
HBase in PracticeHBase in Practice
HBase in Practice
larsgeorge
 
DOAG Oracle Unified Audit in Multitenant Environments
DOAG Oracle Unified Audit in Multitenant EnvironmentsDOAG Oracle Unified Audit in Multitenant Environments
DOAG Oracle Unified Audit in Multitenant Environments
Stefan Oehrli
 
Oracle statistics by example
Oracle statistics by exampleOracle statistics by example
Oracle statistics by example
Mauro Pagano
 
Why oracle data guard new features in oracle 18c, 19c
Why oracle data guard new features in oracle 18c, 19cWhy oracle data guard new features in oracle 18c, 19c
Why oracle data guard new features in oracle 18c, 19c
Satishbabu Gunukula
 
Deep review of LMS process
Deep review of LMS processDeep review of LMS process
Deep review of LMS process
Riyaj Shamsudeen
 
Understanding my database through SQL*Plus using the free tool eDB360
Understanding my database through SQL*Plus using the free tool eDB360Understanding my database through SQL*Plus using the free tool eDB360
Understanding my database through SQL*Plus using the free tool eDB360
Carlos Sierra
 
UKOUG, Oracle Transaction Locks
UKOUG, Oracle Transaction LocksUKOUG, Oracle Transaction Locks
UKOUG, Oracle Transaction LocksKyle Hailey
 
Extreme Replication - Performance Tuning Oracle GoldenGate
Extreme Replication - Performance Tuning Oracle GoldenGateExtreme Replication - Performance Tuning Oracle GoldenGate
Extreme Replication - Performance Tuning Oracle GoldenGate
Bobby Curtis
 
Oracle 10g Performance: chapter 02 aas
Oracle 10g Performance: chapter 02 aasOracle 10g Performance: chapter 02 aas
Oracle 10g Performance: chapter 02 aasKyle Hailey
 
MIgrating from Single Instance to RAC via Dataguard
MIgrating from Single Instance to RAC via DataguardMIgrating from Single Instance to RAC via Dataguard
MIgrating from Single Instance to RAC via Dataguard
Fuad Arshad
 
Oracle GoldenGate 18c - REST API Examples
Oracle GoldenGate 18c - REST API ExamplesOracle GoldenGate 18c - REST API Examples
Oracle GoldenGate 18c - REST API Examples
Bobby Curtis
 
Oracle Active Data Guard 12c: Far Sync Instance, Real-Time Cascade and Other ...
Oracle Active Data Guard 12c: Far Sync Instance, Real-Time Cascade and Other ...Oracle Active Data Guard 12c: Far Sync Instance, Real-Time Cascade and Other ...
Oracle Active Data Guard 12c: Far Sync Instance, Real-Time Cascade and Other ...
Ludovico Caldara
 
Oracle GoldenGate 21c New Features and Best Practices
Oracle GoldenGate 21c New Features and Best PracticesOracle GoldenGate 21c New Features and Best Practices
Oracle GoldenGate 21c New Features and Best Practices
Bobby Curtis
 

What's hot (20)

Oracle Database Performance Tuning Advanced Features and Best Practices for DBAs
Oracle Database Performance Tuning Advanced Features and Best Practices for DBAsOracle Database Performance Tuning Advanced Features and Best Practices for DBAs
Oracle Database Performance Tuning Advanced Features and Best Practices for DBAs
 
Oracle RAC 12c Practical Performance Management and Tuning OOW13 [CON8825]
Oracle RAC 12c Practical Performance Management and Tuning OOW13 [CON8825]Oracle RAC 12c Practical Performance Management and Tuning OOW13 [CON8825]
Oracle RAC 12c Practical Performance Management and Tuning OOW13 [CON8825]
 
Tanel Poder - Scripts and Tools short
Tanel Poder - Scripts and Tools shortTanel Poder - Scripts and Tools short
Tanel Poder - Scripts and Tools short
 
SQL Tuning 101
SQL Tuning 101SQL Tuning 101
SQL Tuning 101
 
Best Practices for the Most Impactful Oracle Database 18c and 19c Features
Best Practices for the Most Impactful Oracle Database 18c and 19c FeaturesBest Practices for the Most Impactful Oracle Database 18c and 19c Features
Best Practices for the Most Impactful Oracle Database 18c and 19c Features
 
Oracle GoldenGate Performance Tuning
Oracle GoldenGate Performance TuningOracle GoldenGate Performance Tuning
Oracle GoldenGate Performance Tuning
 
HBase in Practice
HBase in PracticeHBase in Practice
HBase in Practice
 
DOAG Oracle Unified Audit in Multitenant Environments
DOAG Oracle Unified Audit in Multitenant EnvironmentsDOAG Oracle Unified Audit in Multitenant Environments
DOAG Oracle Unified Audit in Multitenant Environments
 
Oracle statistics by example
Oracle statistics by exampleOracle statistics by example
Oracle statistics by example
 
Why oracle data guard new features in oracle 18c, 19c
Why oracle data guard new features in oracle 18c, 19cWhy oracle data guard new features in oracle 18c, 19c
Why oracle data guard new features in oracle 18c, 19c
 
Deep review of LMS process
Deep review of LMS processDeep review of LMS process
Deep review of LMS process
 
Understanding my database through SQL*Plus using the free tool eDB360
Understanding my database through SQL*Plus using the free tool eDB360Understanding my database through SQL*Plus using the free tool eDB360
Understanding my database through SQL*Plus using the free tool eDB360
 
UKOUG, Oracle Transaction Locks
UKOUG, Oracle Transaction LocksUKOUG, Oracle Transaction Locks
UKOUG, Oracle Transaction Locks
 
Extreme Replication - Performance Tuning Oracle GoldenGate
Extreme Replication - Performance Tuning Oracle GoldenGateExtreme Replication - Performance Tuning Oracle GoldenGate
Extreme Replication - Performance Tuning Oracle GoldenGate
 
Oracle 10g Performance: chapter 02 aas
Oracle 10g Performance: chapter 02 aasOracle 10g Performance: chapter 02 aas
Oracle 10g Performance: chapter 02 aas
 
MIgrating from Single Instance to RAC via Dataguard
MIgrating from Single Instance to RAC via DataguardMIgrating from Single Instance to RAC via Dataguard
MIgrating from Single Instance to RAC via Dataguard
 
Oracle GoldenGate 18c - REST API Examples
Oracle GoldenGate 18c - REST API ExamplesOracle GoldenGate 18c - REST API Examples
Oracle GoldenGate 18c - REST API Examples
 
Convert single instance to RAC
Convert single instance to RACConvert single instance to RAC
Convert single instance to RAC
 
Oracle Active Data Guard 12c: Far Sync Instance, Real-Time Cascade and Other ...
Oracle Active Data Guard 12c: Far Sync Instance, Real-Time Cascade and Other ...Oracle Active Data Guard 12c: Far Sync Instance, Real-Time Cascade and Other ...
Oracle Active Data Guard 12c: Far Sync Instance, Real-Time Cascade and Other ...
 
Oracle GoldenGate 21c New Features and Best Practices
Oracle GoldenGate 21c New Features and Best PracticesOracle GoldenGate 21c New Features and Best Practices
Oracle GoldenGate 21c New Features and Best Practices
 

Similar to Redefining tables online without surprises

Reduce planned database down time with Oracle technology
Reduce planned database down time with Oracle technologyReduce planned database down time with Oracle technology
Reduce planned database down time with Oracle technology
Kirill Loifman
 
Time Travelling With DB2 10 For zOS
Time Travelling With DB2 10 For zOSTime Travelling With DB2 10 For zOS
Time Travelling With DB2 10 For zOS
Laura Hood
 
IDUG NA 2014 / 11 tips for DB2 11 for z/OS
IDUG NA 2014 / 11 tips for DB2 11 for z/OSIDUG NA 2014 / 11 tips for DB2 11 for z/OS
IDUG NA 2014 / 11 tips for DB2 11 for z/OSCuneyt Goksu
 
Reducing Your E-Business Suite Storage Footprint Using Oracle Advanced Compre...
Reducing Your E-Business Suite Storage Footprint Using Oracle Advanced Compre...Reducing Your E-Business Suite Storage Footprint Using Oracle Advanced Compre...
Reducing Your E-Business Suite Storage Footprint Using Oracle Advanced Compre...
Andrejs Karpovs
 
Perfect trio : temporal tables, transparent archiving in db2 for z_os and idaa
Perfect trio : temporal tables, transparent archiving in db2 for z_os and idaaPerfect trio : temporal tables, transparent archiving in db2 for z_os and idaa
Perfect trio : temporal tables, transparent archiving in db2 for z_os and idaa
Cuneyt Goksu
 
Aioug vizag oracle12c_new_features
Aioug vizag oracle12c_new_featuresAioug vizag oracle12c_new_features
Aioug vizag oracle12c_new_features
AiougVizagChapter
 
PostgreSQL Database Slides
PostgreSQL Database SlidesPostgreSQL Database Slides
PostgreSQL Database Slides
metsarin
 
database-stucture-and-space-managment.ppt
database-stucture-and-space-managment.pptdatabase-stucture-and-space-managment.ppt
database-stucture-and-space-managment.ppt
Iftikhar70
 
database-stucture-and-space-managment.ppt
database-stucture-and-space-managment.pptdatabase-stucture-and-space-managment.ppt
database-stucture-and-space-managment.ppt
subbu998029
 
Les09.ppt
Les09.pptLes09.ppt
GLOC 2014 NEOOUG - Oracle Database 12c New Features
GLOC 2014 NEOOUG - Oracle Database 12c New FeaturesGLOC 2014 NEOOUG - Oracle Database 12c New Features
GLOC 2014 NEOOUG - Oracle Database 12c New Features
Biju Thomas
 
How Database Convergence Impacts the Coming Decades of Data Management
How Database Convergence Impacts the Coming Decades of Data ManagementHow Database Convergence Impacts the Coming Decades of Data Management
How Database Convergence Impacts the Coming Decades of Data Management
SingleStore
 
Track 2 session 6 db2 utilities update and best practices v2
Track 2 session 6   db2 utilities update and best practices v2Track 2 session 6   db2 utilities update and best practices v2
Track 2 session 6 db2 utilities update and best practices v2IBMSystemzEvents
 
Powering GIS Application with PostgreSQL and Postgres Plus
Powering GIS Application with PostgreSQL and Postgres Plus Powering GIS Application with PostgreSQL and Postgres Plus
Powering GIS Application with PostgreSQL and Postgres Plus
Ashnikbiz
 
Best Practices for Supercharging Cloud Analytics on Amazon Redshift
Best Practices for Supercharging Cloud Analytics on Amazon RedshiftBest Practices for Supercharging Cloud Analytics on Amazon Redshift
Best Practices for Supercharging Cloud Analytics on Amazon Redshift
SnapLogic
 
OSA Con 2022 - Apache Iceberg_ An Architectural Look Under the Covers - Alex ...
OSA Con 2022 - Apache Iceberg_ An Architectural Look Under the Covers - Alex ...OSA Con 2022 - Apache Iceberg_ An Architectural Look Under the Covers - Alex ...
OSA Con 2022 - Apache Iceberg_ An Architectural Look Under the Covers - Alex ...
Altinity Ltd
 
Technical Introduction to PostgreSQL and PPAS
Technical Introduction to PostgreSQL and PPASTechnical Introduction to PostgreSQL and PPAS
Technical Introduction to PostgreSQL and PPAS
Ashnikbiz
 
Be A Hero: Transforming GoPro Analytics Data Pipeline
Be A Hero: Transforming GoPro Analytics Data PipelineBe A Hero: Transforming GoPro Analytics Data Pipeline
Be A Hero: Transforming GoPro Analytics Data Pipeline
Chester Chen
 
ppt.pdf
ppt.pdfppt.pdf
ppt.pdf
BrahmamKolli
 
Less17 flashback tb3
Less17 flashback tb3Less17 flashback tb3
Less17 flashback tb3Imran Ali
 

Similar to Redefining tables online without surprises (20)

Reduce planned database down time with Oracle technology
Reduce planned database down time with Oracle technologyReduce planned database down time with Oracle technology
Reduce planned database down time with Oracle technology
 
Time Travelling With DB2 10 For zOS
Time Travelling With DB2 10 For zOSTime Travelling With DB2 10 For zOS
Time Travelling With DB2 10 For zOS
 
IDUG NA 2014 / 11 tips for DB2 11 for z/OS
IDUG NA 2014 / 11 tips for DB2 11 for z/OSIDUG NA 2014 / 11 tips for DB2 11 for z/OS
IDUG NA 2014 / 11 tips for DB2 11 for z/OS
 
Reducing Your E-Business Suite Storage Footprint Using Oracle Advanced Compre...
Reducing Your E-Business Suite Storage Footprint Using Oracle Advanced Compre...Reducing Your E-Business Suite Storage Footprint Using Oracle Advanced Compre...
Reducing Your E-Business Suite Storage Footprint Using Oracle Advanced Compre...
 
Perfect trio : temporal tables, transparent archiving in db2 for z_os and idaa
Perfect trio : temporal tables, transparent archiving in db2 for z_os and idaaPerfect trio : temporal tables, transparent archiving in db2 for z_os and idaa
Perfect trio : temporal tables, transparent archiving in db2 for z_os and idaa
 
Aioug vizag oracle12c_new_features
Aioug vizag oracle12c_new_featuresAioug vizag oracle12c_new_features
Aioug vizag oracle12c_new_features
 
PostgreSQL Database Slides
PostgreSQL Database SlidesPostgreSQL Database Slides
PostgreSQL Database Slides
 
database-stucture-and-space-managment.ppt
database-stucture-and-space-managment.pptdatabase-stucture-and-space-managment.ppt
database-stucture-and-space-managment.ppt
 
database-stucture-and-space-managment.ppt
database-stucture-and-space-managment.pptdatabase-stucture-and-space-managment.ppt
database-stucture-and-space-managment.ppt
 
Les09.ppt
Les09.pptLes09.ppt
Les09.ppt
 
GLOC 2014 NEOOUG - Oracle Database 12c New Features
GLOC 2014 NEOOUG - Oracle Database 12c New FeaturesGLOC 2014 NEOOUG - Oracle Database 12c New Features
GLOC 2014 NEOOUG - Oracle Database 12c New Features
 
How Database Convergence Impacts the Coming Decades of Data Management
How Database Convergence Impacts the Coming Decades of Data ManagementHow Database Convergence Impacts the Coming Decades of Data Management
How Database Convergence Impacts the Coming Decades of Data Management
 
Track 2 session 6 db2 utilities update and best practices v2
Track 2 session 6   db2 utilities update and best practices v2Track 2 session 6   db2 utilities update and best practices v2
Track 2 session 6 db2 utilities update and best practices v2
 
Powering GIS Application with PostgreSQL and Postgres Plus
Powering GIS Application with PostgreSQL and Postgres Plus Powering GIS Application with PostgreSQL and Postgres Plus
Powering GIS Application with PostgreSQL and Postgres Plus
 
Best Practices for Supercharging Cloud Analytics on Amazon Redshift
Best Practices for Supercharging Cloud Analytics on Amazon RedshiftBest Practices for Supercharging Cloud Analytics on Amazon Redshift
Best Practices for Supercharging Cloud Analytics on Amazon Redshift
 
OSA Con 2022 - Apache Iceberg_ An Architectural Look Under the Covers - Alex ...
OSA Con 2022 - Apache Iceberg_ An Architectural Look Under the Covers - Alex ...OSA Con 2022 - Apache Iceberg_ An Architectural Look Under the Covers - Alex ...
OSA Con 2022 - Apache Iceberg_ An Architectural Look Under the Covers - Alex ...
 
Technical Introduction to PostgreSQL and PPAS
Technical Introduction to PostgreSQL and PPASTechnical Introduction to PostgreSQL and PPAS
Technical Introduction to PostgreSQL and PPAS
 
Be A Hero: Transforming GoPro Analytics Data Pipeline
Be A Hero: Transforming GoPro Analytics Data PipelineBe A Hero: Transforming GoPro Analytics Data Pipeline
Be A Hero: Transforming GoPro Analytics Data Pipeline
 
ppt.pdf
ppt.pdfppt.pdf
ppt.pdf
 
Less17 flashback tb3
Less17 flashback tb3Less17 flashback tb3
Less17 flashback tb3
 

More from Nelson Calero

Database automation guide - Oracle Community Tour LATAM 2023
Database automation guide - Oracle Community Tour LATAM 2023Database automation guide - Oracle Community Tour LATAM 2023
Database automation guide - Oracle Community Tour LATAM 2023
Nelson Calero
 
Terraform Tips and Tricks - LAOUC 2022
Terraform Tips and Tricks - LAOUC 2022Terraform Tips and Tricks - LAOUC 2022
Terraform Tips and Tricks - LAOUC 2022
Nelson Calero
 
Oracle on kubernetes 101 - Dec/2021
Oracle on kubernetes 101 - Dec/2021Oracle on kubernetes 101 - Dec/2021
Oracle on kubernetes 101 - Dec/2021
Nelson Calero
 
Automate Oracle database patches and upgrades using Fleet Provisioning and Pa...
Automate Oracle database patches and upgrades using Fleet Provisioning and Pa...Automate Oracle database patches and upgrades using Fleet Provisioning and Pa...
Automate Oracle database patches and upgrades using Fleet Provisioning and Pa...
Nelson Calero
 
Oracle Exadata Cloud Services guide from practical experience - OOW19
Oracle Exadata Cloud Services guide from practical experience - OOW19Oracle Exadata Cloud Services guide from practical experience - OOW19
Oracle Exadata Cloud Services guide from practical experience - OOW19
Nelson Calero
 
Automate your oracle cloud infrastructure operations v2.0 - OOW19
Automate your oracle cloud infrastructure operations v2.0 - OOW19Automate your oracle cloud infrastructure operations v2.0 - OOW19
Automate your oracle cloud infrastructure operations v2.0 - OOW19
Nelson Calero
 
Automate the operation of your Oracle Cloud infrastructure v2.0
Automate the operation of your Oracle Cloud infrastructure v2.0Automate the operation of your Oracle Cloud infrastructure v2.0
Automate the operation of your Oracle Cloud infrastructure v2.0
Nelson Calero
 
SSL certificates in the Oracle Database without surprises
SSL certificates in the Oracle Database without surprisesSSL certificates in the Oracle Database without surprises
SSL certificates in the Oracle Database without surprises
Nelson Calero
 
Practical guide to Oracle Virtual environments
Practical guide to Oracle Virtual environmentsPractical guide to Oracle Virtual environments
Practical guide to Oracle Virtual environments
Nelson Calero
 
Automate your Oracle Cloud Infrastructure operation
Automate your Oracle Cloud Infrastructure operationAutomate your Oracle Cloud Infrastructure operation
Automate your Oracle Cloud Infrastructure operation
Nelson Calero
 
Welcome to databases in the Cloud
Welcome to databases in the CloudWelcome to databases in the Cloud
Welcome to databases in the Cloud
Nelson Calero
 
Protect Sensitive Data: Implementing Fine-Grained Access Control in Oracle
Protect Sensitive Data: Implementing Fine-Grained Access Control in OracleProtect Sensitive Data: Implementing Fine-Grained Access Control in Oracle
Protect Sensitive Data: Implementing Fine-Grained Access Control in Oracle
Nelson Calero
 
Evolution of Performance Management: Oracle 12c adaptive optimizations - ukou...
Evolution of Performance Management: Oracle 12c adaptive optimizations - ukou...Evolution of Performance Management: Oracle 12c adaptive optimizations - ukou...
Evolution of Performance Management: Oracle 12c adaptive optimizations - ukou...
Nelson Calero
 
Oracle Exadata Maintenance tasks 101 - OTN Tour 2015
Oracle Exadata Maintenance tasks 101 - OTN Tour 2015Oracle Exadata Maintenance tasks 101 - OTN Tour 2015
Oracle Exadata Maintenance tasks 101 - OTN Tour 2015
Nelson Calero
 
My Experience Using Oracle SQL Plan Baselines 11g/12c
My Experience Using Oracle SQL Plan Baselines 11g/12cMy Experience Using Oracle SQL Plan Baselines 11g/12c
My Experience Using Oracle SQL Plan Baselines 11g/12c
Nelson Calero
 
Oracle RAC sin sorpresas - v2014
Oracle RAC sin sorpresas - v2014Oracle RAC sin sorpresas - v2014
Oracle RAC sin sorpresas - v2014
Nelson Calero
 
Alta disponibilidad con Pacemaker
Alta disponibilidad con PacemakerAlta disponibilidad con Pacemaker
Alta disponibilidad con Pacemaker
Nelson Calero
 
AROUG BIDAY 2013 - Automatizar procesos de ETL con PL/SQL
AROUG BIDAY 2013 - Automatizar procesos de ETL con PL/SQLAROUG BIDAY 2013 - Automatizar procesos de ETL con PL/SQL
AROUG BIDAY 2013 - Automatizar procesos de ETL con PL/SQL
Nelson Calero
 
MariaDB y FOSS en infraestructura de salud y estándares
MariaDB y FOSS en infraestructura de salud y estándaresMariaDB y FOSS en infraestructura de salud y estándares
MariaDB y FOSS en infraestructura de salud y estándares
Nelson Calero
 
UYOUG 2012 - Oracle RAC 11gR2 - New features
UYOUG 2012 - Oracle RAC 11gR2 - New featuresUYOUG 2012 - Oracle RAC 11gR2 - New features
UYOUG 2012 - Oracle RAC 11gR2 - New features
Nelson Calero
 

More from Nelson Calero (20)

Database automation guide - Oracle Community Tour LATAM 2023
Database automation guide - Oracle Community Tour LATAM 2023Database automation guide - Oracle Community Tour LATAM 2023
Database automation guide - Oracle Community Tour LATAM 2023
 
Terraform Tips and Tricks - LAOUC 2022
Terraform Tips and Tricks - LAOUC 2022Terraform Tips and Tricks - LAOUC 2022
Terraform Tips and Tricks - LAOUC 2022
 
Oracle on kubernetes 101 - Dec/2021
Oracle on kubernetes 101 - Dec/2021Oracle on kubernetes 101 - Dec/2021
Oracle on kubernetes 101 - Dec/2021
 
Automate Oracle database patches and upgrades using Fleet Provisioning and Pa...
Automate Oracle database patches and upgrades using Fleet Provisioning and Pa...Automate Oracle database patches and upgrades using Fleet Provisioning and Pa...
Automate Oracle database patches and upgrades using Fleet Provisioning and Pa...
 
Oracle Exadata Cloud Services guide from practical experience - OOW19
Oracle Exadata Cloud Services guide from practical experience - OOW19Oracle Exadata Cloud Services guide from practical experience - OOW19
Oracle Exadata Cloud Services guide from practical experience - OOW19
 
Automate your oracle cloud infrastructure operations v2.0 - OOW19
Automate your oracle cloud infrastructure operations v2.0 - OOW19Automate your oracle cloud infrastructure operations v2.0 - OOW19
Automate your oracle cloud infrastructure operations v2.0 - OOW19
 
Automate the operation of your Oracle Cloud infrastructure v2.0
Automate the operation of your Oracle Cloud infrastructure v2.0Automate the operation of your Oracle Cloud infrastructure v2.0
Automate the operation of your Oracle Cloud infrastructure v2.0
 
SSL certificates in the Oracle Database without surprises
SSL certificates in the Oracle Database without surprisesSSL certificates in the Oracle Database without surprises
SSL certificates in the Oracle Database without surprises
 
Practical guide to Oracle Virtual environments
Practical guide to Oracle Virtual environmentsPractical guide to Oracle Virtual environments
Practical guide to Oracle Virtual environments
 
Automate your Oracle Cloud Infrastructure operation
Automate your Oracle Cloud Infrastructure operationAutomate your Oracle Cloud Infrastructure operation
Automate your Oracle Cloud Infrastructure operation
 
Welcome to databases in the Cloud
Welcome to databases in the CloudWelcome to databases in the Cloud
Welcome to databases in the Cloud
 
Protect Sensitive Data: Implementing Fine-Grained Access Control in Oracle
Protect Sensitive Data: Implementing Fine-Grained Access Control in OracleProtect Sensitive Data: Implementing Fine-Grained Access Control in Oracle
Protect Sensitive Data: Implementing Fine-Grained Access Control in Oracle
 
Evolution of Performance Management: Oracle 12c adaptive optimizations - ukou...
Evolution of Performance Management: Oracle 12c adaptive optimizations - ukou...Evolution of Performance Management: Oracle 12c adaptive optimizations - ukou...
Evolution of Performance Management: Oracle 12c adaptive optimizations - ukou...
 
Oracle Exadata Maintenance tasks 101 - OTN Tour 2015
Oracle Exadata Maintenance tasks 101 - OTN Tour 2015Oracle Exadata Maintenance tasks 101 - OTN Tour 2015
Oracle Exadata Maintenance tasks 101 - OTN Tour 2015
 
My Experience Using Oracle SQL Plan Baselines 11g/12c
My Experience Using Oracle SQL Plan Baselines 11g/12cMy Experience Using Oracle SQL Plan Baselines 11g/12c
My Experience Using Oracle SQL Plan Baselines 11g/12c
 
Oracle RAC sin sorpresas - v2014
Oracle RAC sin sorpresas - v2014Oracle RAC sin sorpresas - v2014
Oracle RAC sin sorpresas - v2014
 
Alta disponibilidad con Pacemaker
Alta disponibilidad con PacemakerAlta disponibilidad con Pacemaker
Alta disponibilidad con Pacemaker
 
AROUG BIDAY 2013 - Automatizar procesos de ETL con PL/SQL
AROUG BIDAY 2013 - Automatizar procesos de ETL con PL/SQLAROUG BIDAY 2013 - Automatizar procesos de ETL con PL/SQL
AROUG BIDAY 2013 - Automatizar procesos de ETL con PL/SQL
 
MariaDB y FOSS en infraestructura de salud y estándares
MariaDB y FOSS en infraestructura de salud y estándaresMariaDB y FOSS en infraestructura de salud y estándares
MariaDB y FOSS en infraestructura de salud y estándares
 
UYOUG 2012 - Oracle RAC 11gR2 - New features
UYOUG 2012 - Oracle RAC 11gR2 - New featuresUYOUG 2012 - Oracle RAC 11gR2 - New features
UYOUG 2012 - Oracle RAC 11gR2 - New features
 

Recently uploaded

GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
James Anderson
 
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Thierry Lestable
 
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
Sri Ambati
 
UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
DianaGray10
 
FIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdfFIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance
 
Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
Alan Dix
 
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualitySoftware Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Inflectra
 
Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........
Alison B. Lowndes
 
JMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and GrafanaJMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and Grafana
RTTS
 
Assuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyesAssuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyes
ThousandEyes
 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
DanBrown980551
 
To Graph or Not to Graph Knowledge Graph Architectures and LLMs
To Graph or Not to Graph Knowledge Graph Architectures and LLMsTo Graph or Not to Graph Knowledge Graph Architectures and LLMs
To Graph or Not to Graph Knowledge Graph Architectures and LLMs
Paul Groth
 
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdfFIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance
 
The Future of Platform Engineering
The Future of Platform EngineeringThe Future of Platform Engineering
The Future of Platform Engineering
Jemma Hussein Allen
 
ODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User GroupODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User Group
CatarinaPereira64715
 
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdfSmart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
91mobiles
 
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdfFIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance
 
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Product School
 
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
Product School
 

Recently uploaded (20)

GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
 
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
 
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
 
UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
 
FIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdfFIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdf
 
Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
 
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualitySoftware Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
 
Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........
 
JMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and GrafanaJMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and Grafana
 
Assuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyesAssuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyes
 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
 
To Graph or Not to Graph Knowledge Graph Architectures and LLMs
To Graph or Not to Graph Knowledge Graph Architectures and LLMsTo Graph or Not to Graph Knowledge Graph Architectures and LLMs
To Graph or Not to Graph Knowledge Graph Architectures and LLMs
 
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdfFIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
 
The Future of Platform Engineering
The Future of Platform EngineeringThe Future of Platform Engineering
The Future of Platform Engineering
 
ODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User GroupODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User Group
 
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdfSmart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
 
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdfFIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
 
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...
 
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
 

Redefining tables online without surprises

  • 1. Redefining Tables Online Without Surprises Latin American OTN Tour – August 2017 Nelson Calero
  • 2. • Database Consultant at Pythian since 2014 • Working with Oracle tools and Linux environments since 1996 • DBA Oracle (2001) & MySQL (2005) • Co-founder and President of the Oracle user Group of Uruguay (2009) • LAOUC Director of events (2013) • Computer Engineer (1998) • Oracle ACE (2014), Oracle ACE Director (2017) • Oracle Certified Professional DBA 10g/11g/12c (2008) • Amazon Solutions Architect – Associate since (2016) • Oracle University Instructor (2011) • Blogger and speaker: Oracle Open World, Collaborate, OTN Tour, Regional conferences About me 2 © 2017 Pythian http://www.linkedin.com/in/ncalero @ncalerouy
  • 3. Pythian overview © 2015 Pythian Confidential3 • 20 Years of data infrastructure management consulting • 250+ Top brands • 11800+ systems under management • 400+ employees in 35 countries • 10 Oracle ACEs, 4 ACED, 3 OakTable members, 2 OCM, 6 Microsoft MVPs, 1 Cloudera Champion of Big Data, AWS Certified Solutions Architect – 2 Professional, 12 Associate • Oracle, Microsoft, MySQL, Hadoop, Cassandra, MongoDB, and more • Infrastructure, Cloud, DevOps, and application expertise
  • 4. Online table redefinition • Motivation • Online DDL review • dbms_redefinition examples • Changes in different Oracle versions • Known restrictions • Problems found • Real life usage to compress a VLDB 4 © 2017 Pythian
  • 5. Motivation • DDL operations have different optimizations to make it faster – DDL locks are held (shared or exclusive) while operation runs – Larger tables with some DDL that do not implement optimizations will keep locks longer • DML automatically grab locks to keep consistency – Row Locks (TX) and Table Locks (TX) using different modes: RS, RX, S, SRX, X – Conflicting locks will delay running transactions – More visible with large tables and heavy concurrency • Some example DDLs: – Change table columns: add/drop/modify attributes (name, datatype, length, compression, etc.) – Move a table to a different tablespace – Partition a non-partitioned table (and vice-versa) – Compress an uncompressed table (and vice-versa) – Reorganize data to change physical layout • rows per block (PCTFREE), Ordering (clustering factor) 5 © 2017 Pythian
  • 6. Optimized DDL operations - example • Adding a column to a table: ALTER TABLE t1 ADD C1 number; • Metadata updated, no change made to existing rows • Including now a default value: ALTER TABLE t1 ADD C1 number default 1; • Before 12c: existing rows are updated adding the new value • Since 12c: metadata updated, no changes to existing rows • Restrictions with LOBs, IOTs, temporary, MVs, VPD, encryption, queue • NOT NULL instead of NULL: ALTER TABLE t1 ADD C1 number default 1 not null ; • Before 11g – existing rows are updated adding the new value • Since 11g – metadata updated, no changes to existing rows https://docs.oracle.com/database/121/SQLRF/statements_3001.htm#CIHGHAJG http://www.oracle.com/technetwork/articles/database/ddl-optimizaton-in-odb12c-2331068.html 6 © 2017 Pythian
  • 7. Example Terminal 1: watch -d --interval=1 "sqlplus -s / as sysdba @locks | tee -a watch.log" Terminal 2: - Generate DML (ex: insert a record without commit) Terminal 3: - Play with DDL - Example: alter table add / drop column, index, constraints 7 © 2017 Pythian
  • 8. Today’s focus • We are looking to modify the structure of a table without blocking other users’ transactions – Also known as Online DDL – Highlighted as HA features (as no application downtime is required) • Several operations already implemented as online in Oracle if conditions are met (details to follow) • Some only available on Enterprise Edition (EE) 8 © 2017 Pythian
  • 9. Online operations in Oracle • Only in Enterprise Edition – Online index rebuild – since 8i – Online index-organized table organization (alter table move) – Online table redefinition (dbms_redefinition) – since 9i – Online partition/sub-partition move – since 12.1 – Online table move – since 12.2 – Online SPLIT Partition and Subpartition – since 12.2 • Restrictions apply per functionality and version – Example: bitmaps, IOTs, Parallel DML, column datatypes • Note the ‘online’ clause needs to be added to the SQL statement alter index T1_IDX rebuild online; alter table T1 move online tablespace NEW_TS; 9 © 2017 Pythian
  • 10. Online DDL – poor’s man approach - Create empty table with the changes needed - Copy source rows to modified table - Copy changes received since operation started - repeat as needed (controlling amount of data moved each time) - lock table in exclusive mode - interchange old and new table (renaming both) - Goal is to minimize the exclusive lock duration - Dependent objects needs to be created manually - Constraints, indices, triggers – pre-creating them disabled adds run-time overhead - Names should be interchanged with original ones • Several examples from open source databases – pt-online-schema-change (MySQL - Percona), osc_cli (MySQL – Facebook) – pg_repack (PostgreSQL) 10 © 2017 Pythian
  • 11. Online operations in Oracle • Obvious thing to remark: RTFM !! – Features change in versions – Restrictions for each operation based on structure – Patches to fix known bugs • Example: ALTER TABLE <table> MOVE … – On 12.2 the ONLINE option allows DML against the <table> while it runs • dbms_redefinition is needed before 12.2 – Indexes are marked unusable because ROWID changes • ORA-1502 reported by queries using those indexes – LOB columns are not moved by default • we need to include it explicitly if we want to move them with the table 11 © 2017 Pythian
  • 12. Example: moving a single partition • In Oracle 12.1: alter table test.T1 move partition P4 online update indexes; • Bug 'Inconsistent Datatypes: Expected NUMBER (Doc ID 2028583.1)‘ on 12.1.0.2.170117 - needs one-off patch 20703000 • Physical attributes gets copied - if we plan to change them, better to do it before moving: alter table test.T1 modify default attributes STORAGE(INITIAL 1048576 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645); alter table test.T1 move partition P4 online update indexes; • Pre-12.1: only using dbms_redefinition 12 © 2017 Pythian
  • 13. dbms_redefinition • Available since version 9i to allow online DDL • A snapshot log is automatically created saving changes while data is copied • Resync as many times as needed (good to resume failures) • Minimum time needed for the final step to rename tables • Needs 2x original space – a temporal (interim) table is used – Don’t forget increasing redolog activity, archivelog space and standby transport • Simplified in 12c for some use cases – One procedure does all the work, but is less flexible 13 © 2017 Pythian
  • 14. dbms_redefinition - workflow 14 © 2017 Pythian Original Index1 Index2
  • 15. dbms_redefinition - workflow 15 © 2017 Pythian Original Index1 Index2 Interim Index1$ 1 create interim table
  • 16. dbms_redefinition - workflow 16 © 2017 Pythian Original Index1 Index2 Interim Index1$ 2 Start redefinition MLOG
  • 17. dbms_redefinition - workflow 17 © 2017 Pythian Original Index1 Index2 Interim Index1$ MLOG 3 Sync redefinition
  • 18. dbms_redefinition - workflow 18 © 2017 Pythian Original Index1 Index2 Interim Index1$ Index2$ MLOG 4 Copy dependent objects
  • 19. dbms_redefinition - workflow 19 © 2017 Pythian Original Index1 Index2 Interim Index1$ Index2$ MLOG 5 Finish redefinition (1/2)
  • 20. dbms_redefinition - workflow 20 © 2017 Pythian Interim Index1$ Index2$ Original Index1 Index2 5 Finish redefinition (2/2) MLOG
  • 21. dbms_redefinition – complete workflow 21 © 2017 Pythian Original table Index1 Index2 Interim table Index1 Index2 1 2 create interim table Start redefinition MLOG 3 Sync redefinition 5 Finish redefinition 4 Copy dependent objects
  • 22. dbms_redefinition – 12c simple usage DBMS_REDEFINITION.REDEF_TABLE ( uname IN VARCHAR2, tname IN VARCHAR2, table_compression_type IN VARCHAR2 := NULL, table_part_tablespace IN VARCHAR2 := NULL, index_key_compression_type IN VARCHAR2 := NULL, index_tablespace IN VARCHAR2 := NULL, lob_compression_type IN VARCHAR2 := NULL, lob_tablespace IN VARCHAR2 := NULL, lob_store_as IN VARCHAR2 := NULL) We can combine all parameters in a single execution to:  compress table and all LOBs  change tablespace for table (or all partitions), all indexes and all LOBs  change LOB to store as SECUREFILE or BASICFILE 22 © 2017 Pythian
  • 23. dbms_redefinition – 12c example Moving an entire table changing table, indexes and LOBs attributes: begin DBMS_REDEFINITION.REDEF_TABLE ( uname => 'TEST', tname => 'T1', table_compression_type => 'ROW STORE COMPRESS ADVANCED', table_part_tablespace => 'TEST_COMP', index_key_compression_type => 'COMPRESS ADVANCED LOW', index_tablespace => 'TEST_IDX_COMP', lob_compression_type => 'COMPRESS HIGH', lob_tablespace => 'TEST_COMP', lob_store_as => 'SECUREFILE'); end; NOTE: Table and index owner (TEST) needs quota privilege on new tablespace TEST_COMP. 23 © 2017 Pythian
  • 24. dbms_redefinition – 12c example Demo – example1.sql Compressing a partitioned table, doing some validations and discovering some issues: - hidden columns created when using ROWID - NOVALIDATE constraints after redefinition (BUG 4396234) - see concurrency effect NOTE: All examples used in this presentation are in dropbox 24 © 2017 Pythian
  • 25. dbms_redefinition - restrictions • Same schema • LONG and LONG RAW columns cannot be redefined – cannot be moved manually either (alter table .. move) – LONG columns must be converted to CLOBS – LONG RAW columns must be converted to BLOBS – needs application testing • NOTE: BFILE columns can be redefined online starting on 12.2 • Known bugs with one-off patch available (11.2.0.4 example): - 18889295 - ORA-600 [4511] kdbchk: row locked by non-existent transaction on OLTP compressed table - 21887221 - Primary Key Constraint index changes after redefinition when a primary key index is a subset of another normal index being present on the same table 25 © 2017 Pythian
  • 26. dbms_redefinition – long approach 1) Manually create the interim table with the changes we want 2) Validates if table can be redefined online DBMS_REDEFINITION.can_redef_table (owner, seg, flag, part); 3) Start Redefinition DBMS_REDEFINITION.start_redef_table (owner, seg, interim, part); 4) Apply changes captured while previous step ran DBMS_REDEFINITION.sync_interim_table (owner, seg, interim); 5) Copy dependent objects DBMS_REDEFINITION.copy_table_dependents (owner, seg, interim, errors); 6) Finish – exchange table names (p_seg and p_int_tab) DBMS_REDEFINITION.finish_redef_table (owner, seg, interim, part); 26 © 2017 Pythian
  • 27. dbms_redefinition – short or long usage? Old approach (with more steps) needed in 12c for: • structural changes • moving only some partitions/lobs/indexes (not all) • Not recommended for structural changes start_redef_table offers some extra features: – Reorder rows using order by clause (orderby_cols parameter) – Copy only some columns, or create new combining functions to existing ones (col_mapping parameter) NOTE: data is copied without generating UNDO (APPEND hint is used in the INSERT statement) 27 © 2017 Pythian
  • 28. dbms_redefinition – COPY_TABLE_DEPENDENTS • Clone indexes, privileges, triggers, constraints and statistics • Triggers and referential integrity constraints are created disabled, enabled automatically after redefinition completes • All cloned objects are renamed to the original names when redefinition completes – interim table is the original table at that point, having internal names for cloned objects History: • Added in 10g • Since 11.1 dependent objects are not invalidated (PL/SQL, views, synonyms etc.) 28 © 2017 Pythian
  • 29. dbms_redefinition – new in 12.2 • V$ONLINE_REDEF Progress reported by START_REDEF_TABLE and COPY_TABLE_DEPENDENTS • Restarting redefinition after failures DBA_REDEFINITION_STATUS view includes new columns to identify the object and error, allowing to resolve error and resume failed operation Example: datafile full when executing SYNC • Rolling back redefinition after it was completed New parameter ENABLE_ROLLBACK in START_REDEF_TABLE New procedures ABORT_ROLLBACK and ROLLBACK After completing a redefinition with rollback enabled, MLOG is not dropped. We can SYNC after that to keep old source table (now interim) updated, until we decide to rollback or abort it • BFILE columns support • SYNC_INTERIM_TABLE can incremental refresh dependent MVs on the interim table 29 © 2017 Pythian
  • 30. dbms_redefinition – troubleshooting • Errors are recorded in dba_redefinition_errors – From redefinition step (first) and copy dependent objects procedure – Nothing from compact 12c REDEF_TABLE – it works or aborts • Manual procedure allows to fix errors and resume • To cancel a non completed redef DBMS_REDEFINITION.ABORT_REDEF_TABLE • If in doubt: SQL trace of the session running redefinition 30 © 2017 Pythian
  • 31. dbms_redefinition – more examples Demo – example2.sql : 11g approach to move a single partition - Using DBMS_METADATA.GET_DDL to generate interim table - See concurrency effect and data movement – example3.sql – redefining a table having hidden columns 31 © 2017 Pythian
  • 32. dbms_redefinition – troubleshooting examples Demo – example4.sql: solving errors when copying constraints • Interim table have NOT NULL columns and we try to copy constraints using copy_table_dependents • Side effect after resolving it with final table structure – example5.sql: solving error when copying index • Source table has a bitmap index, using copy_table_dependents gives error • Using register_dependent_object to redefine table 32 © 2017 Pythian
  • 33. dbms_redefinition – Summary • Redefine using PK if available – Avoid hidden column added when using ROWID (known issue as per MOS 459762.1) • When creating Interim table, columns should be nullable to avoid errors when copying dependent – Use dbms_metadata.get_ddl to automate it • NOT NULL constraints are left NOVALIDATE after clone – Bug:4396234 - we need to modify them after redefinition completes • To exclude a particular objects from COPY_TABLE_DEPENDENTS: – Use REGISTER_DEPENDENT_OBJECT before – object must be manually pre-created, and will be renamed at the end • Optimizer stats can be copied – check if that makes sense for you – Clustering factor change - data is defragmented, orderby clause can be used, pctfree can change, etc. 33 © 2017 Pythian
  • 34. Real life approach to compress VLDB Procedure outline – By object or tablespace approach? – Identify objects to exclude (matching known restrictions) • both for dbms_redefinition and compression – Plan space needs – 2x for each table (and index) – Automate whenever possible – dropping objects too? – Able to split indexes from table maintenance? • Needs application usage planning, as it could affect SQL using them Facts – 30Tb database, 350 tablespaces, 2000 datafiles – Combination of all datatypes and structures • IOTs, partitioned, basicfile LOBs, LONG – More than 24hs needed to redefine 1Tb tables – Different space savings found – floor around 2x 34 © 2017 Pythian
  • 36. References - documentation • DBMS_REDEFINITION - 12.2 Database PL/SQL Packages and Types Reference https://docs.oracle.com/database/122/ARPLS/DBMS_REDEFINITION.htm#ARPLS042 • Automatic Locks in DML Operations - 12.2 Database SQL Language Reference https://docs.oracle.com/database/122/SQLRF/Automatic-Locks-in-DML-Operations.htm#SQLRF55502 • Managing Tables - 12.2 Database Administrator’s Guide https://docs.oracle.com/database/122/ADMIN/managing-tables.htm • All examples in this presentation are in dropbox, http://bit.ly/2w71qxb 36 © 2017 Pythian
  • 37. dbms_redefinition – common issues 1) ORA-12093: invalid interim table "OWNER"."TABLE" • Intermediate table named in the “redef_table” is not created yet 2) ORA-12089: cannot online redefine table "OWNER"."TABLE" with no primary key • A table with no PK was tried to be redefined without using the ROWID option 3) ORA-23539: table "OWNER"."NAME" currently being redefined • Table redefinition finished with errors and a new “redef_table” was run If data was already copied and failure was during copy dependents steps, we don’t need to drop the table and start again - we can keep the already copied data, resolve errors, sync and repeat copy dependants. 37 © 2017 Pythian
  • 38. dbms_redefinition – common issues (2) 4) ORA-00997: illegal use of LONG datatype • Columns LONG, LONG RAW and BFILE cannot be redefined. https://docs.oracle.com/cd/B28359_01/server.111/b28310/tables007.htm#ADMIN11674 5) ORA-23541: tables do not match tables used while defining the redefinition • When COPY_TABLE_DEPENDENTS is used for a single partition, it tries to copy partitioned table objects when target is not partitioned and only an exchange partition will be executed Solution: • copying dependents should not be used when moving single partitions 38 © 2017 Pythian
  • 39. dbms_redefinition – unexpected issues 6) ORA-25965: fact table must be included in the from clause • This is because index DDL generated by redefinition contains reference to source table without being changed to the new name SQL reported in DBA_REDEFINITION_ERRORS.DDL_TXT: CREATE BITMAP INDEX "TEST"."TMP$$_IDX_JOIN0" ON "TEST"."T3_RDEF" ("T97912"."CODE") FROM "TEST"."T2" "T97912", "TEST"."T3" "T97911" WHERE "T97911"."ID"="T97912"."BUCK_ID“ Solution: • manually create index with the correct name before starting • exclude index from redefinition using REGISTER_DEPENDENT_OBJECT 39 © 2017 Pythian
  • 40. dbms_redefinition – unexpected issues (2) 7) ORA-14024: number of partitions of LOCAL index must equal that of the underlying table • Interim table was created using dbms_metadata, but it got table and index creation with less partitions than the existing one (not updated with new partitions added) Solution: • Manually adjust interim table creation SQL adding missing partitions from existing index 8) ORA-01442: column to be modified to NOT NULL is already NOT NULL • Intermediate table was created with not null columns Solution: • Remove not null constraint from interim table and retry desc will show table not having not null constraints, but the check constraint is there and enabled 1) drop check constraints on interim tables 2) resync, retry copy dependent and finish redefinition 3) enable validate check constraints Caused by a known bug:4396234 ET10.2OREDEF: NULLABLE COL OF *_TAB_COLUMNS TABLE NOT UPDATED AFTER ONLINE REDEF 40 © 2017 Pythian