My Oracle Support Banner

How To Exchange A Partition To Existing Table With Historical Data (Doc ID 2622715.1)

Last updated on MARCH 29, 2020

Applies to:

MySQL Server - Version 8.0 and later
Information in this document applies to any platform.

Goal

Consider that the tables used in this practice are the following:

The main table "t1" is partitioned on year basis and it has records on partition "p2019".

Objective is that once a year is completed, the specific year partition should be moved to history table and it has to be removed from main table. 

How to append the specific partition p2019 from "t1" to "t2" table using EXCHANGE PARTITION command while retaining all existing data from "t2" table?

Solution

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Goal
Solution
References


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.