Open Source RDBMS - Seamless, Scalable, Stable and Free

한국어 | Login |Register

Versions available for this page: CUBRID 8.3.0 |  CUBRID 8.3.1 |  CUBRID 8.4.0 |  CUBRID 8.4.1 |  CUBRID 8.4.3 |  CUBRID 9.0.0 | 

Dropping List Partitioning

Description

You can drop a partition by using the DROP PARTITION clause of the ALTER statement.

Syntax

ALTER {TABLE | CLASS} <table_name>
DROP PARTITION <partition_name>

  • table_name : Specifies the name of the partitioned table.
  • partition_name: Specifies the name of the partition to be dropped.
Example

The following example shows how to create the athlete2 table partitioned by the list of sport events and drop the event3 partition.

CREATE TABLE athlete2( name VARCHAR(40), event VARCHAR(30) )

PARTITION BY LIST (event) (

PARTITION event1 VALUES IN ('Swimming', 'Athletics ' ),

PARTITION event2 VALUES IN ('Judo', 'Taekwondo','Boxing'),

PARTITION event3 VALUES IN ('Football', 'Basketball', 'Baseball')

);

 

ALTER TABLE athlete2 DROP PARTITION event3;