List-range partition

Hi Oracle Gurus,
I have a table with list partition, as the partitions are growing large I need to create subpartitions.
Is it possible to create a range subpartition under list partition. If yes I need that subpartition to be built on time not on date.
Is it possible.

While range-list partitioning exists in 10g, list-range partitioning to the best of my knowledge does not exist. There are some new options in 11g but I can't remember what they are off the top of my head. You can check the on-line documentation to see what your partitioning options are
Your partitioning options will depend on what version of Oracle you are using. Also remember that you need the licence to use the partitioning feature

Similar Messages

  • Create list-range partition table

    Database version: Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bi
    I am trying to create a partition table with LIST-Range, and I am getting this following error, is oracle 10.2.0.4 database supports to create list-range partition(composite)
    SQL> CREATE TABLE tbp_list_range
    REPORT_DATE DATE,
    member_id_01 varchar2(2),
    DATE_SERVICE date,
    member_id varchar2(15)
    PARTITION BY LIST(member_id_01)
    SUBPARTITION BY RANGE (DATE_SERVICE)
    PARTITION SPTYR04M01_C VALUES('AA','aa')
    NOLOGGING
    COMPRESS (
    SUBPARTITION PTYR12M011 VALUES LESS THAN (TO_DATE(' 2012-01-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN')),
    SUBPARTITION PTYR12M021 VALUES LESS THAN (TO_DATE(' 2012-02-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN')),
    SUBPARTITION recent1 VALUES LESS THAN (MAXVALUE)
    PARTITION SPTYR04M01_Yo VALUES('BJ','bj')
    NOLOGGING
    COMPRESS (
    SUBPARTITION PTYR12M01 VALUES LESS THAN (TO_DATE(' 2012-01-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN')),
    SUBPARTITION PTYR12M02 VALUES LESS THAN (TO_DATE(' 2012-02-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN')),
    SUBPARTITION recent2 VALUES LESS THAN (MAXVALUE)
    SUBPARTITION BY RANGE (DATE_SERVICE)
    ERROR at line 9:
    ORA-00922: missing or invalid option
    SQL> select * from v$version;
    BANNER
    Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bi
    PL/SQL Release 10.2.0.4.0 - Production
    CORE 10.2.0.4.0 Production
    TNS for Linux: Version 10.2.0.4.0 - Production
    NLSRTL Version 10.2.0.4.0 - Production
    Any help would be greatly appreciated.
    Thanks,

    any possible work around for this scenario on 10.2.0.4
    --thanks                                                                                                                                                                                               

  • Oracle 11g  List - Range Partition - Help Needed

    Hi All,
    I want to create a composite partition (LIST-RANGE) but RANGE partition should using interval partition
    This is my query .
    CREATE TABLE "DMSDB"."DEVICE_UTILS"
    (     "ULID" VARCHAR2(100 CHAR),
         "IP_ADDRESS" VARCHAR2(24 CHAR),
         "PORT" VARCHAR2(8 CHAR),
         "SHUTDOWN" NUMBER(10,0),
         "LINE_TYPE" NUMBER(10,0) DEFAULT '0',
         "OCCUPIED" NUMBER(10,0),
         "UTILIZATION" NUMBER(10,0),
         "IDLE_TIME" VARCHAR2(32 CHAR),
         "ACTIVATION_TIME" VARCHAR2(32 CHAR),
         "PULLED_DATE" TIMESTAMP (6) DEFAULT SYSDATE,
         "ACCESS_TIME" TIMESTAMP (6) DEFAULT SYSDATE
    PARTITION BY LIST(ULID)
              PARTITION PART_DEVUTILS_ULID VALUES (DEFAULT)
         SUBPARTITION BY RANGE( PULLED_DATE)
         PARTITION PART_DEVUTILS_WEEK INTERVAL (NUMTOYMINTERVAL(1,'WEEK'))
    Somehow its not working. can you please suggest where i am making mistake?

    Interval partitioning is not supported at the subpartition level.
    http://docs.oracle.com/cd/B28359_01/server.111/b28286/statements_7002.htm#BABCDDIA
    Regards
    Girish Sharma

  • List-range partition and subpartition

    Does anyone know that Oracle 10g support partition by list and subpartition by range? Thanks.

    check the documentation link [http://download.oracle.com/docs/cd/B19306_01/appdev.102/b31695/dialogs.htm#sthref441]
    hope you will find your answer on link page.

  • NULL partition key in RANGE partition

    All,
    This is regarding partitioning a table using RANGE partition method. But the partition key contains null. How do I handle this situation? This is because there is no DEFAULT partition in RANGE partition though its present in LIST partition. Will rows with NULL partition key fall in MAXVALUE partition? Seeking your guidence.
    Thanks,
    ...

    NULLS would fit into the MAXVAL partition yes.
    http://download.oracle.com/docs/cd/B19306_01/server.102/b14220/partconc.htm#sthref2590
    Thanks
    Paul

  • Is there any plan of allowing non-range partitioning of spatial indexes

    our application is really lacking the ability of spatial index being partitioned by list. We are binning information in our data warehouse by spatial locations, and when we query it (actually, MapViewer is generating a tile), entire geometry set is searched because table is list-partitioned and we cannot have local spatial index.

    Hi,
    I'm not in a position to answer the question about list partitioning, but would a pseudo-list partition implemented as a range partition work? For example, something like this:
    CREATE TABLE customers (
      first_name    VARCHAR2(20),
      last_name     VARCHAR2(20),
      address_1     VARCHAR2(20),
      address_2     VARCHAR2(20),
      city          VARCHAR2(20),
      state_abrv    VARCHAR2(3),
      postal_code   VARCHAR2(10),
      customer_id   NUMBER NOT NULL UNIQUE)
      PARTITION BY RANGE (state_abrv) 
       PARTITION ALASKA         VALUES LESS THAN ('AKz'),
       PARTITION ALABAMA        VALUES LESS THAN ('ALz'),
       PARTITION ARKANSAS       VALUES LESS THAN ('ARz'),
       PARTITION AMERICANSAMOA  VALUES LESS THAN ('ASz'),
       PARTITION ARIZONA        VALUES LESS THAN ('AZz'),
       PARTITION CALIFORNIA     VALUES LESS THAN ('CAz'),
       PARTITION WYOMING        VALUES LESS THAN ('WYz')
       );I've used this method in the past, although I agree a list partitioning solution is much preferred.
    Dan

  • Subpartition existing range partition in Oracle

    I have table xyz with following structure
    xyz ( vld_dte date,
    prd_typ varchar2(100),
    sales number
    table XYZ is partitioned by range on field vld_dte and partitions are monthly partitions like JAN-2009 , FEB-2009....DEC-2009 and so on.table is currently loaded with data.
    How can I modify existing range partition into composite range-list partition so that every partiton is subpartitioned on prd_typ , basically three sub-partitions for every partition 1- Grocery , 2-Home decoration,3-OTHERS

    ORA-14759: SET INTERVAL is not legal on this table.
    Cause: ALTER TABLE SET INTERVAL is only legal on a range partitioned table with a single partitioning column. Additionally this table cannot have a maxvalue partition.
    Action: Use SET INTERVAL only on a valid table
    mark answered post as helpful / correct*

  • Problem with a 2 columns Range Partitioning for a indexed organized table

    have an indexed organized table with a 2 column PK. the first field (datum) is a date field the second field (installatieid) is a number(2) field.
    Every minute a 7 records are inserted (installatieid 0-6).
    I like to partition this table with one partition per year per installatieid.
    I tried to do it with:
    partition by range(datum,installatieid)
    (partition P_2004_0 values less than (to_date('2004-01,'yyyy-mm'),1)
    ,partition P_2004_6 values less than (to_date('2004-01','yyyy-mm'),7)
    partition P_2005_0 values less than (to_date('2005-01','yyyy-mm'),1)
    ,partition P_2005_6 values less than (to_date('2005-01','yyyy-mm'),7)
    but now only the P_2004_0 and P_2005_0 are filled.
    I thought about to combine a range partition on datum with a list subpartition on installatieid, but I read this is not allowed with an index organized table.
    How can I solve this problem.

    partition by range(datum,installatieid)
    (partition P_2004_0 values less than
    (to_date('2004-01,'yyyy-mm'))
    ,partition P_2004_6 values less than
    (to_date('2004-07','yyyy-mm'))
    partition P_2005_0 values less than
    (to_date('2005-01','yyyy-mm'))
    ,partition P_2005_6 values less than
    (to_date('2005-07','yyyy-mm'))
    ? Sorry haven't got time to test it this morning ;0)

  • Using range partition

    my table has partition and subpartition like -----
    PARTITION BY RANGE (SEGMENT_)
    SUBPARTITION BY LIST (DATE_FOR_PURGE)
    PARTITION S_1 VALUES LESS THAN (2)
    NOLOGGING
    NOCOMPRESS
    TABLESPACE TAO_TBL
    ( SUBPARTITION S_1_D_99999999 VALUES (99999999) TABLESPACE TAO_TBL,
    SUBPARTITION S_1_D_20100520 VALUES (20100520) TABLESPACE TAO_TBL,
    SUBPARTITION S_1_D_20100628 VALUES (20100628) TABLESPACE TAO_TBL,
    SUBPARTITION S_1_D_20100629 VALUES (20100629) TABLESPACE TAO_TBL,
    SUBPARTITION S_1_D_20100705 VALUES (20100705) TABLESPACE TAO_TBL,
    SUBPARTITION S_1_D_20100708 VALUES (20100708) TABLESPACE TAO_TBL,
    SUBPARTITION S_1_D_20100930 VALUES (20100930) TABLESPACE TAO_TBL,
    SUBPARTITION S_1_D_20101001 VALUES (20101001) TABLESPACE TAO_TBL,
    SUBPARTITION S_1_D_20101002 VALUES (20101002) TABLESPACE TAO_TBL )
    i want to use partition in the select clause
    what will be the query?

    You mean that you want to explicitly set the partition in the select statement?
    SELECT <column list>
    FROM    <table name>
    PARTITION (<partition name>)
    WHERE<predicates>

  • Unique key on range-partitioned table

    Hi,
    We are using a composite range-hash interval partitioned table
    Uses index - trying to make this have same tablespace as the partitions i.e. local but not liking it
    alter table RETAILER_TRANSACTION_COMP_POR
    add constraint RETAILER_TRANSACTION_COMP_PK primary key (DWH_NUM)
    using index
    LOCAL
    ora-14039: partitioning columns must form a subset of key columns of a unique index
    Without local then fine but doesn't have same tablespace as the partitions and don't want to make this part of partition key.
    Tbale range partitioned - this is just a UK to prevent duplicates

    [oracle@localhost ~]$ oerr ora 14039
    14039, 00000, "partitioning columns must form a subset of key columns of a UNIQUE index"
    // *Cause:  User attempted to create a UNIQUE partitioned index whose
    //          partitioning columns do not form a subset of its key columns
    //          which is illegal
    // *Action: If the user, indeed, desired to create an index whose
    //          partitioning columns do not form a subset of its key columns,
    //          it must be created as non-UNIQUE; otherwise, correct the
    //          list of key and/or partitioning columns to ensure that the index'
    //          partitioning columns form a subset of its key columns

  • Existing Range partition to Interval Partition

    I have an Range and list partition tables on Oracle 11g with some records and have to move the
    range and List partition tables to interval partitions. I tried for the range partition
    table with following query,
    SQL> alter table F_PTP_PAYMENTS set interval (numtoyminterval(3,'MONTH'));
    alter table F_PTP_PAYMENTS set interval (numtoyminterval(3,'MONTH'))
    ERROR at line 1:
    ORA-14759: SET INTERVAL is not legal on this table.
    it doesnt worked out.
    Can you please help me to create the interval partitions.

    ORA-14759: SET INTERVAL is not legal on this table.
    Cause: ALTER TABLE SET INTERVAL is only legal on a range partitioned table with a single partitioning column. Additionally this table cannot have a maxvalue partition.
    Action: Use SET INTERVAL only on a valid table
    mark answered post as helpful / correct*

  • About range partition

    Dear Friends ,
    I am using Oracle10g . I have to create a range partition like below :
    CREATE TABLE EMP
    EMPNO NUMBER(4),
    ENAME VARCHAR2(10 BYTE),
    JOB VARCHAR2(9 BYTE),
    MGR NUMBER(4),
    HIREDATE DATE,
    SAL NUMBER(7,2),
    COMM NUMBER(7,2),
    DEPTNO NUMBER(2)
    PARTITION BY RANGE(hiredate)
    PARTITION emp_1980 VALUES LESS THAN(TO_DATE('31/12/1980','DD/MM/YYYY')) TABLESPACE USERS,
    PARTITION emp_1981 VALUES LESS THAN(TO_DATE('31/12/1981','DD/MM/YYYY')) TABLESPACE USERS,
    PARTITION emp_1982 VALUES LESS THAN(TO_DATE('31/12/1982','DD/MM/YYYY')) TABLESPACE USERS,
    PARTITION emp_1987 VALUES LESS THAN(TO_DATE('31/12/1987','DD/MM/YYYY')) TABLESPACE USERS
    But the problem is :
    1) if any input data is not match with the above criteria then where it goes ? i mean , the data which dont follow the above rule which partition it goes ? is there any way to set DEFAULT partition option in the range partition ?
    I only find the DEFAULT option in LIST partition
    2) Barring this , when I add a new partition with the above then it shows the below error :
    alter table emp add partition emp.emp_1988 VALUES LESS THAN(TO_DATE('31/12/1988','DD/MM/YYYY')) TABLESPACE USERS
    Error :
    "ORA-14020: this physical attribute may not be specified for a table partition" ,
    Would anybody plz help me , How can I solve the above problems ?

    Range Partitioning provides for a range of values. Therefore, any value higher than the maximum value provided in your partition definitions would fail. Thus, for example, 01/01/1988 and above would error. That is why Range Partitioning allows you to specify a "highest" values possible where you say "values less than (MAXVALUE)". Therefore, if you had included an "emp_maxvalue" partition with "values less than (MAXVALUE)" after the "emp_1987" partition, any value for 1988 or higher would go into the emp_maxvalue partition.
    { Since there is no minvalue specified, a value of, say, 01/06/1979 would go into the "emp_1980" partition as it is "less than (01/01/1980)" ! }
    Again, as Partitioning is a Range of Dates, you cannot add a partition. You have to SPLIT a partition. For example, if you had an "emp_maxvalue" partition present, in order to create the emp_1988 partition, you would SPLIT "emp_maxvalue" into two partitions : emp_1988 and emp_maxvalue.
    Please read the documentation on Partition Maintenance in the Administrator's Guide.
    Hemant K Chitale
    http://hemantoracledba.blogspot.com

  • Create range partition

    hi ,
    Oracle 10.2.0.1.0
    I'm getting error while creating a range partition to already existing table (method employed : partition swap method ) .
    PF screen shot of error
    SQL> ed
    Wrote file afiedt.buf
      1  create table employee_details_temp partition by range (eid) (
      2  partition eid_1r values less than (1000)
      3  partition eid_2r values less than (20000)
      4  partition eid_3r values less than (40000)
      5  partition eid_3r values less than (maxvalue)
      6* )
    SQL> /
    partition eid_2r values less than (20000)
    ERROR at line 3:
    ORA-14020: this physical attribute may not be specified for a table partitionalso ,
    SQL> ed
    Wrote file afiedt.buf
      1  create table employee_details_temp partition by range (eid) (
      2  partition eid_1r values less than (1000)
      3  partition eid_2r values less than (20000)
      4  partition eid_3r values less than (40000)
      5  partition eid_3r values less than (maxvalue)
      6  ) as select * from employee_details where 1=1;
      7* /
    SQL> /
    partition eid_2r values less than (20000)
    ERROR at line 3:
    ORA-14020: this physical attribute may not be specified for a table partition please help .

    answered .

  • How to find out the min & max partition_id in a range partition?

    Hi we have a table set up by range partition
    In the table creation script. It goes something like:
    PARTITION PARTD_CUST_3_1_NEW VALUES LESS THAN ('39500')
    so how we can find out this number '39500' from some of the data_dictionary view?
    What we want to do is to set up parallel processing (do-it-yourself) based on partition.
    So the number of parallel process will be based on this ID-range.
    I can find out how many partitions are there by using something like this:
    SELECT COUNT(*)
    FROM all_tab_partitions WHERE table_owner='OWNER_NAME' AND table_name='TABLE_NAME'
    We have 5 partitions now but the table structure can change in the near future even this table has moer than 130Million rows
    I do not want to hardcode this "39500" just in case the table structure changes (partition structure changes)
    Any idea ??

    vxwo0owxv wrote:
    Hi we have a table set up by range partition
    In the table creation script. It goes something like:
    PARTITION PARTD_CUST_3_1_NEW VALUES LESS THAN ('39500')
    so how we can find out this number '39500' from some of the data_dictionary view?
    What we want to do is to set up parallel processing (do-it-yourself) based on partition.
    So the number of parallel process will be based on this ID-range.
    I can find out how many partitions are there by using something like this:
    SELECT COUNT(*)
    FROM all_tab_partitions WHERE table_owner='OWNER_NAME' AND table_name='TABLE_NAME'
    We have 5 partitions now but the table structure can change in the near future even this table has moer than 130Million rows
    I do not want to hardcode this "39500" just in case the table structure changes (partition structure changes)
    Any idea ??query DBA_TAB_PARTITIONS.HIGH_VALUE

  • Non-Partitioned Global Index on Range-Partitioned Table.

    Hi All,
    Is it possible to create Non-Partitioned Global Index on Range-Partitioned Table?
    We have 4 indexes on CS_BILLING range-partitioned table, in which one is CBS_CLIENT_CODE(*local partitioned index*) and others are unknown types of index to me??
    Means other 3 indexes are what type indexes ...either non-partitioned global index OR non-partitioned normal index??
    Also if we create index as :(create index i_name on t_name(c_name)) By default it will create Global index. Please correct me......
    Please help me in identifying other 3 indexes types by referring below ouputs!!!
    select INDEX_NAME,TABLE_NAME,PARTITIONING_TYPE,LOCALITY from dba_part_indexes where TABLE_NAME='CS_BILLING';
    INDEX_NAME TABLE_NAME PARTITI LOCALI
    CSB_CLIENT_CODE CS_BILLING RANGE LOCAL
    select index_name,index_type,table_name,table_type,PARTITIONED from dba_indexes where table_name='CS_BILLING';
    INDEX_NAME INDEX_TYPE TABLE_NAME TABLE_TYPE PAR
    CSB_CREATE_DATE NORMAL CS_BILLING TABLE NO
    CSB_SUBMIT_ORDER NORMAL CS_BILLING TABLE NO
    CSB_CLIENT_CODE NORMAL CS_BILLING TABLE YES
    CSB_ORDER_NBR NORMAL CS_BILLING TABLE NO
    select INDEX_OWNER,INDEX_NAME,TABLE_NAME,COLUMN_NAME from dba_ind_columns where TABLE_NAME='CS_BILLING';
    INDEX_OWNER INDEX_NAME TABLE_NAME COLUMN_NAME
    RPADMIN CSB_CREATE_DATE CS_BILLING CREATE_DATE
    RPADMIN CSB_SUBMIT_ORDER CS_BILLING SUBMIT_TO_INVOICE
    RPADMIN CSB_SUBMIT_ORDER CS_BILLING ORDER_NBR
    RPADMIN CSB_CLIENT_CODE CS_BILLING CLIENT_CODE
    RPADMIN CSB_ORDER_NBR CS_BILLING ORDER_NBR
    select dip.index_name, dpi.locality, dip.partition_name, dip.status
    from dba_part_indexes dpi, dba_ind_partitions dip
    where dpi.table_name ='CS_BILLING'
    and dpi.index_name = dip.index_name;
    INDEX_NAME LOCALI PARTITION_NAME STATUS
    CSB_CLIENT_CODE LOCAL CSB_2006_4Q USABLE
    CSB_CLIENT_CODE LOCAL CSB_2006_3Q USABLE
    CSB_CLIENT_CODE LOCAL CSB_2007_1Q USABLE
    CSB_CLIENT_CODE LOCAL CSB_2007_2Q USABLE
    CSB_CLIENT_CODE LOCAL CSB_2007_3Q USABLE
    CSB_CLIENT_CODE LOCAL CSB_2007_4Q USABLE
    CSB_CLIENT_CODE LOCAL CSB_2008_1Q USABLE
    CSB_CLIENT_CODE LOCAL CSB_2008_2Q USABLE
    CSB_CLIENT_CODE LOCAL CSB_2008_3Q USABLE
    CSB_CLIENT_CODE LOCAL CSB_2008_4Q USABLE
    CSB_CLIENT_CODE LOCAL CSB_2009_1Q USABLE
    CSB_CLIENT_CODE LOCAL CSB_2009_2Q USABLE
    CSB_CLIENT_CODE LOCAL CSB_2009_3Q USABLE
    CSB_CLIENT_CODE LOCAL CSB_2009_4Q USABLE
    select * from dba_part_indexes
    where table_name ='CS_BILLING'
    and locality = 'GLOBAL';
    no rows selected
    -Yasser
    Edited by: YasserRACDBA on Mar 5, 2009 11:45 PM

    Yaseer,
    Is it possible to create Non-Partitioned and Global Index on Range-Partitioned Table?
    Yes
    We have 4 indexes on CS_BILLING range-partitioned table, in which one is CBS_CLIENT_CODE(*local partitioned index*) and others are unknown types of index to me??
    Means other 3 indexes are what type indexes ...either non-partitioned global index OR non-partitioned normal index??
    You got local index and 3 non-partitioned "NORMAL" b-tree tyep indexes
    Also if we create index as :(create index i_name on t_name(c_name)) By default it will create Global index. Please correct me......
    Above staement will create non-partitioned index
    Here is an example of creating global partitioned indexes
    CREATE INDEX month_ix ON sales(sales_month)
       GLOBAL PARTITION BY RANGE(sales_month)
          (PARTITION pm1_ix VALUES LESS THAN (2)
           PARTITION pm2_ix VALUES LESS THAN (3)
           PARTITION pm3_ix VALUES LESS THAN (4)
            PARTITION pm12_ix VALUES LESS THAN (MAXVALUE));Regards

Maybe you are looking for

  • Using CopyIntoItems from Copy.asmx from a remote soap client

    Hello, I have been working on a soap client that runs on a remote client (not on the SharePoint server) and is platform-independent so that it cannot use the SP Object Model. I have managed to get most of the functionality working using SharePoint we

  • Syncing events in alphabetic order on my I pad as I have on my Mac

    I have organized my events in I photo in alphabetic order and have synced several times to my I pad but yet the event order on my I pad still does not match that of my Mac... (Is there a way to organize the events in alphabetic order on my I pad??)

  • Can't Get MediaNet Icon

    Hello. I recently purchased a used 8310 (AT&T) online and I noticed there was no MediaNet icon. I have tried wiping the device and registering the service books and battery pull, but none have worked. There is not even a MediaNet option when I go to

  • Update to Reports 6i

    I am curious as to how to tell (via metalink or otherwise) if a Patch to Reports 6i has been released? I filed a TAR back in May that was dealing with the Servlet Inteface to the reports engine. What is the current version (i.e 6.0.8.x.x) that should

  • Master data text deletion-urgent pls

    Hello Is there any other way to delete the master data text from the text table other than deleting from SE11 or SE16? the delete option is greyed out in SE16 and SE11. Is there any other way to delete the entries without affecting other objects? Reg