Hello, i would neeed to create a one-partition table which is structurally identical to an existing big partitioned table.
Say I have a table T, I need to create T0 with exactly the same columns *and storage specifications* as T, but restricted to a single partition.
Somethig akin to "create table T0 as select * from T where 1=0", but with only one partition that shares all the same characteristics as those of the source table.
I have used DBMS_METADATA.GET_DDL in the past for similar needs, but it includes the definitions of *all partitions* which i want to avoid in the present case.
The goal is to iterate in PL/SQL over the partitions of T, select from one with some transformation into T0,
then swap the only T0 partition with the partition at hand from T.