Which three operations can be performed as multipartition operations in Oracle?
A.
Merge partitions of a list partitioned table
B.
Drop partitions of a list partitioned table
C.
Coalesce partitions of a hash-partitioned global index.
D.
Move partitions of a range-partitioned table
E.
Rename partitions of a range partitioned table
F.
Merge partitions of a reference partitioned index
Explanation:
Multipartition maintenance enables adding, dropping, truncate, merge, split
operations on multiple partitions.
A: Merge Multiple Partitions:
The new “ALTER TABLE … MERGE PARTITIONS ” help merge multiple partitions or
subpartitions with a single statement. When merging multiple partitions, local and global index
operations and semantics for inheritance of unspecified physical attributes are the same for
merging two partitions.
B: Drop Multiple Partitions:
The new “ALTER TABLE … DROP PARTITIONS ” help drop multiple partitions or subpartitions
with a single statement.
Example:
view plaincopy to clipboardprint?
SQL> ALTER TABLE Tab_tst1 DROP PARTITIONS
Tab_tst1_PART5, Tab_tst1_PART6, Tab_tst1_PART7;
Table altered
SQL>
Restrictions :
– You can’t drop all partitions of the table.
– If the table has a single partition, you will get the error: ORA-14083: cannot drop the only partition
of a partitioned.
These operations cannot be performed on reference-partitioned tables. If performed on a parent table, then these operations cascade to all descendant tables.
F is incorrect. D, E are single partition statements. I’d go with ABC.
http://docs.oracle.com/database/121/VLDBG/part_admin002.htm#CHDJCEEF
ABC
http://docs.oracle.com/database/121/VLDBG/part_admin002.htm
The ALTER TABLE COALESCE PARTITION statement is used to coalesce a partition in a hash partitioned table.
You cannot merge partitions for a reference-partitioned table.
ABC.
https://docs.oracle.com/database/121/VLDBG/part_admin002.htm#VLDBG1145
“Multipartition maintenance operations enable adding multiple partitions to a table, dropping multiple partitions, merging multiple partitions into one partition, splitting of a single partition into multiple partitions, and truncating multiple partitions using a single SQL data definition language (DDL) statement. For a summary of valid maintenance operations on partitions, subpartitions, and indexes, see the Oracle Database VLDB and Partitioning Guide.”
http://www.oracle.com/webfolder/technetwork/tutorials/obe/db/12c/Partitioning/12c_parti.html#section5
Thus, ADD, DROP, MERGE, SPLIT and TRUNCATE -> A and B straightforward.
I think the key word in F is ‘reference’, for the associated partitioned indexes would also be merged.
Not C,D,E – COALESCE, MOVE, RENAME.
A&B&C
The response cg conclusive and docs are very clear. Thanks.
All answers can be found in table 4.1 here:
Maintenance Operations on Partitions That Can Be Performed
http://docs.oracle.com/database/121/VLDBG/GUID-79391819-DCEF-46AC-977D-199BD2044DA2.htm#VLDBG14070
A, B and C are correct.
ABC
https://docs.oracle.com/database/121/VLDBG/GUID-320603FD-0A7B-409D-A5E3-22C5D98E5A5A.htm
For this reason C is incorrect.