Oracle range Partition maintenance information

Hello
I would like to know the range between oldest partition and the new partition on a table. an organization can help me with this?
I have a query that gives me all the partition tables in the database, now I would like to get the date of the oldest partition and the new partition to get the retention period... any help would be appreciated...

Here's what I get all the partition tables
SELECT table_owner, table_name, max (partition_name)
FROM dba_tab_partitions p
WHERE p.table_name IN
select (separate c.TABLE_NAME
dba_part_key_columns p, dba_tab_cols c
where p.name = c.TABLE_NAME
and p.column_name = c.COLUMN_NAME
and p.object_type = 'TABLE '.
and c.DATA_TYPE = 'DATE '.
and p.owner NOT IN ("SYS", "SYSTEM"))
and p.table_name not like '% BIN ".
Group of table_owner, table_name
order of table_owner;

What is your version of Oracle 4-digit?

Provide an example of a table and what you consider to be "older" and "newer" partitions Are you talking about tables that are partitioned? INTERVAL of partitioned? What about the subpartitions?

Why your query uses MAX (partition_name)? How is that useful information - partitions may have all the names including system generated ones.

And why the oldest and newest you would give the retention period?

For simple RANGE partitioned tables the info of the range is in the column HIGH_VALUE (a LONG - so need to use PL/SQL) from DBA_TAB_PARTITIONS.

Suggests that you first train a step by step manual process to do what you want to do and then work on automating it.
Show me an example of your manual process.

Tags: Database

Similar Questions

  • Size of partition on interval range partitioned Table happens when SYSDATE is used in a Where Clause

    We have tables interval range partitioned on a DATE, with a partition for each day column - very standard and straight out of doc Oracle.

    A 3rd party application queries the tables to find the number of rows based on the date range that is located on the column used for the partition key.

    This application uses the date range specified from the current date - i.e. for last two days would be «...» StartDate > SYSDATE-2 "- but the partition size is irrelevant and the explain command plan shows that each partition is included."

    In presenting the request uses the date in a variable partition size location and query table is obviously much better.

    DB is 11.2.0.3 on RHEL6, and default settings - i.e. nothing that could influence the behavior of the optimizer to something unusual.

    I can't work on why this would be the case. It is very easy to reproduce with cases of simple test below.

    I would be very interested to hear any views on why it's that way and if anything can be done to allow the size of the partition to work with a query including SYSDATE because it would be difficult to get the application code has changed.

    In addition to make a case to change the code, I need an explanation of why query using SYSDATE is not advisable and I know this information.

    (1) create a simple partitioned table

    CREATETABLE part_test
       (id                      NUMBER NOT NULL,
        starttime               DATE NOT NULL,
        CONSTRAINT pk_part_test PRIMARY KEY (id)) 
    PARTITION BY RANGE (starttime) INTERVAL (NUMTODSINTERVAL(1,'day')) (PARTITION p0 VALUES LESS THAN (TO_DATE('01-01-2013','DD-MM-YYYY')));
    

    (2) fill in the rows of the table 1 million distributed among 10 partitions

    BEGIN
        FOR i IN 1..1000000
        LOOP
            INSERT INTO part_test (id, starttime) VALUES (i, SYSDATE - DBMS_RANDOM.value(low => 1, high => 10));
        END LOOP;
    END;
    /
    EXEC dbms_stats.gather_table_stats('SUPER_CONF','PART_TEST');
    

    (3) to query the Table of data from the last 2 days using SYSDATE in paragraph

    EXPLAIN PLAN FOR 
    SELECT  count(*) 
    FROM    part_test
    WHERE   starttime >= SYSDATE - 2;
    

    -------------------------------------------------------------------------------------------------------

    | ID | Operation | Name | Lines | Bytes | Cost (% CPU). Time | Pstart. Pstop |

    -------------------------------------------------------------------------------------------------------

    |   0 | SELECT STATEMENT |           |     1.     3 ×  7895 (1) | 00:00:01 |       |       |

    |   1.  GLOBAL TRI |           |     1.     3 ×            |          |       |       |

    |   2.   RANGE OF PARTITION ITERATOR.           |   111K |   867K |  7895 (1) | 00:00:01 |   KEY | 1048575.

    |*  3 |    TABLE ACCESS FULL | PART_TEST |   111K |   867K |  7895 (1) | 00:00:01 |   KEY | 1048575.

    -------------------------------------------------------------------------------------------------------

    Information of predicates (identified by the operation identity card):

    ---------------------------------------------------

    3 - filter("STARTTIME">=SYSDATE@!-2)

    (4) now do the same query, but with SYSDATE - 2 presented as a literal value.

    This query returns the same response but very different cost.

    EXPLAIN PLAN FOR
    SELECT count(*) 
    FROM part_test
    WHERE starttime >= (to_date('23122013:0950','DDMMYYYY:HH24MI'))-2;
    

    -------------------------------------------------------------------------------------------------------

    | ID | Operation | Name | Lines | Bytes | Cost (% CPU). Time | Pstart. Pstop |

    -------------------------------------------------------------------------------------------------------

    |   0 | SELECT STATEMENT |           |     1.     8.   131 (0) | 00:00:01 |       |       |

    |   1.  GLOBAL TRI |           |     1.     8.            |          |       |       |

    |   2.   RANGE OF PARTITION ITERATOR.           |   111K |   867K |   131 (0) | 00:00:01 |   356 . 1048575.

    |*  3 |    TABLE ACCESS FULL | PART_TEST |   111K |   867K |   131 (0) | 00:00:01 |   356 | 1048575.

    -------------------------------------------------------------------------------------------------------

    Information of predicates (identified by the operation identity card):

    ---------------------------------------------------

    3 filter ("STARTTIME" > = TO_DATE (' 2013-12-21 09:50 ',' syyyy-mm-dd hh24:mi:ss'))))

    Thank you in anticipation

    Jim

    sysdate is not constant and its value may change from time optimization of execution; but the optimizer can deduce that he will be a known running value and then produce a plan that will make the size of partition running.  This is the meaning of 'KEY' in the column pstart – the partition of departure will be known at run time and the size of partition will take place in order to eliminate the previous partitions.

    Concerning

    Jonathan Lewis

  • Range partitioning of a table. Max to set value

    Hello

    I use a partitioned table range, range partitioned to date and have set the max value such as 6 months after the Date of creation.
    I have a proc that creates the partitions, I want to advance to split the max score.

    -Now what do I do when the max score is reached after 6 months?
    -If I set the max score one or two years after the current date instead of the currently defined 6 months after the date of creation. What are the negative aspects attached with it?

    I can't use the Partition interval and must use Range only.
    Please suggest.


    Thank you...

    >
    In fact, I'll create the daily partitions. But I intend to create a week pf partitions in advance, rather than creating one every day.
    It wise or should I create daily partition, insert some data into it. Then the next day, create the partition again and so on...
    Or each week to create a week of partitions in advance.
    >
    It's to you how you want to do the maintenance activity.

    Maybe you have information the rest of us don't but my sources tell me that tomorrow, the next day and so on will continue to arrive in this exact order, day after day in the foreseeable future. This isn't like creating partitions for December will be useless.

    Like I said above
    >
    And there is really no penalty to create partitions in advance. So you may want to consider the creation of partitions, you will need by the end of the year at least and then make a month at a time or, if partitioning by month per quarter (3 months) at a time.

  • Oracle Excessive Partition table

    People,
    We have a server Oracle 10 g. My question concerns an Oracle table that until now has 183 scores. Whoever created this table, put in place to add a new partition at the end of each month. I checked and verified in each partition, there are anywhere between 20 000 and 40 000 lines. Each line consists of 218 bytes. My manager is to get rid of these partitions. He just wants me to check that let down the barriers would not impact the response time that much. I can see Adding a partition of all ranks from 500 000 to 1 000 000, but having a partition for 20, 000 to 40 000 lines seems excessive to me. At the pace partitions are added to this table, in 5 years, it might have more than 600 scores. Finally, like anything else in life, there must be some back of draw for Oracle table partitioning. I saw a lot of 'Pros' on the Web but not 'jerks '.

    I would appreciate your opinion on it.

    Seyed

    I agree with your idea that the partitioning for 40K lines (with the information provided) seems excessive. Do the calculation lines 40 K * 218 partitions should be out only about 8 million, I would not immediately consider a candidate for partitioning.

    Partitioning of the benefits that you are aware of; most of them involves the use of large data sets. Pruning is a huge advantage by excluding the vast amounts of data that are unwanted review of the join.

    There are disadvantages too, for the most part buried under the volume of data partitions work usually with. There is a performance slightly beat on standard queries against a partitioned table while SQL decides which partitions to hit. You can observe this by querying the table, then by a specific partition trying only to get data for a specific partition.

    There is also the question of how many partitions you want to keep track of? You ask the right questions.

    Its possible that the partitions help performance; the only way to be sure is to create a table that is not partitioned using DEC, indexes, and constraints such as the partitioned table and run performance tests.

  • Where and how Oracle Forms stores its information on locked records?

    Where and how Oracle Forms stores its information on locked records?

    Is there a specific lock that contains user information or table time for locked records?

    I m using Oracle (Forms) 11 g

    Thanks in advance!

    Oracle uses a byte in each record in the lock ("lock byte"). See:

    http://www.DBA-Oracle.com/t_locks_row_level_locking_update.htm

    and

    http://docs.Oracle.com/CD/E11882_01/server.112/e41084/ap_locks001.htm#SQLRF55502

    http://psoug.org/blogs/Mohan/exploring-internal-params/detect-and-resolve-locks/

    ...

    Kind regards

    Zlatko

  • TIMESTAMP (6) partitioned key-> range partitioned table ddl needed

    What is the DDL TIMESTAMP syntax (6) partitioned key, range partitioned table

    Published by: oracletune on January 11, 2013 10:26

    >
    What is the DDL TIMESTAMP syntax (6) partitioned key, range partitioned table
    >
    Don't know what you're asking. Are you asking how to create a table partitioned using a TIMESTAMP column (6) for the key?

    CREATE TABLE TEST1
    (
        USERID                 NUMBER,
        ENTRYCREATEDDATE     TIMESTAMP(6)
    )
    PARTITION BY RANGE (ENTRYCREATEDDATE) INTERVAL(NUMTOYMINTERVAL(1, 'MONTH'))
    (
        PARTITION P0 VALUES LESS THAN (TO_DATE('1-1-2013', 'DD-MM-YYYY'))
    )
    

    See my answer posted: January 10, 2013 21:56 if you need to do on a TIMESTAMP with TIME ZONE column. You must add a virtual column.
    Creating scores of auto range

  • Oracle partitioning range Partitioning

    Aloha!

    Our scheme has existing partition. I shared the larger partition with the script below:

    ALTER table table_name
    Split partition PART_NAME to ('YYYYMMDD')
    into (partition PART_NAME1, partition PART_NAME);

    When I check the partition has said after the execution of the separation, I was invited...

    * SQL > select "| p.table_name |': ' | p.PARTITION_NAME: ", p.num_rows of all_tab_partitions p where p.table_name = 'TABLE_NAME' - order by p.table_name; *

    *''|| P.TABLE_NAME |': ' | P.PARTITION_NAME | " NUM_ROWS *.
    ------------------------------------------------------------- ----------
    TABLE_NAME:Q3_                                                            0
    TABLE_NAME:Q4_                                                            0
    TABLE_NAME:PART_NAME1 0
    TABLE_NAME:PART_NAME 0

    The initial state of the partition has been...

    * SQL > select "| p.table_name |': ' | p.PARTITION_NAME: ", p.num_rows of all_tab_partitions p where p.table_name = 'TABLE_NAME' - order by p.table_name; *

    *''|| P.TABLE_NAME |': ' | P.PARTITION_NAME | " NUM_ROWS *.
    ------------------------------------------------------------- ----------
    TABLE_NAME:Q3_                                                    0
    TABLE_NAME:Q4_                                                    0
    TABLE_NAME:PART_NAME 14000000

    My question is, why there is no record of the new partition to split it took an another 24 hours after I got this result?

    SQL > select "| p.table_name |': ' | p.PARTITION_NAME |", all_tab_partitions p.num_rows p where p.table_name = 'TABLE_NAME' order of p.table_name *.

    *''|| P.TABLE_NAME |': ' | P.PARTITION_NAME | " NUM_ROWS *.
    ------------------------------------------------------------- ----------
    TABLE_NAME:Q3_                                                    0
    TABLE_NAME:Q4_                                                    0
    TABLE_NAME:PART_NAME1 555338
    TABLE_NAME:PART_NAME 862207

    Database: Oracle Database 11 g Enterprise Edition Release 11.2.0.1.0 - 64 bit Production

    Thank you in advance.

    Kind regards
    Hades

    Num_rows (as well as a variety of other columns data dictionary) is fulfilled when collect you statistics on the partition. You really should have gathered fresh statistics after splitting the partition. Presumably, either the default background work or work that you (or your DBA) has race calculated the statistics on the table during your window at night.

    Justin

  • Range partitioned table is not created in the compressed format interavl

    Hello

    Using oracle 11.2.03. and trying to create a table with compress


    Fine regular table but challenging syntax below but tabel properties don't show no compression

    Tried to compress at the top of the sql as described and down

    Aldso tried to compress and compress for oltp - bahviour even do not get compressed.

    Now HSOING at the TABLE LEVEL or ON TABLE PORPETIES BUT WHEN check user_tab_partitions shows compressed for oltp

    Thank you
    create table RETAILER_TRANSACTION_comP_POR parallel
    COMPRESS FOR OLTP
    
    partition by range (PARTITIONING_DATE)
    INTERVAL (NUMTOYMINTERVAL(1,'MONTH'))
    subpartition by hash (PLANT_ISSUE_ID) 
    subPARTITIONS 4
    (
      partition PART_200912 values less than (TO_DATE(' 2010-01-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_200912
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201001 values less than (TO_DATE(' 2010-02-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201001
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201002 values less than (TO_DATE(' 2010-03-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201002
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201003 values less than (TO_DATE(' 2010-04-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201003
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201004 values less than (TO_DATE(' 2010-05-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201004
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201005 values less than (TO_DATE(' 2010-06-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201005
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201006 values less than (TO_DATE(' 2010-07-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201006
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201007 values less than (TO_DATE(' 2010-08-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
      tablespace RTRN_PART_201007
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201008 values less than (TO_DATE(' 2010-09-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201008
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201009 values less than (TO_DATE(' 2010-10-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201009
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201010 values less than (TO_DATE(' 2010-11-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201010
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201011 values less than (TO_DATE(' 2010-12-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201011
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201012 values less than (TO_DATE(' 2011-01-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201012
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201101 values less than (TO_DATE(' 2011-02-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201101
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201102 values less than (TO_DATE(' 2011-03-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201102
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201103 values less than (TO_DATE(' 2011-04-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201103
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201104 values less than (TO_DATE(' 2011-05-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201104
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201105 values less than (TO_DATE(' 2011-06-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201105
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201106 values less than (TO_DATE(' 2011-07-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201106
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201107 values less than (TO_DATE(' 2011-08-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201107
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201108 values less than (TO_DATE(' 2011-09-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201108
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201109 values less than (TO_DATE(' 2011-10-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201109
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201110 values less than (TO_DATE(' 2011-11-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201110
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201111 values less than (TO_DATE(' 2011-12-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201111
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201112 values less than (TO_DATE(' 2012-01-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
       tablespace RTRN_PART_201112
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201201 values less than (TO_DATE(' 2012-02-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201201
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201202 values less than (TO_DATE(' 2012-03-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
         tablespace RTRN_PART_201202
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201203 values less than (TO_DATE(' 2012-04-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201203
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201204 values less than (TO_DATE(' 2012-05-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201204
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201205 values less than (TO_DATE(' 2012-06-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
         tablespace RTRN_PART_201205
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201206 values less than (TO_DATE(' 2012-07-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201206
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201207 values less than (TO_DATE(' 2012-08-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
       tablespace RTRN_PART_201207
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201208 values less than (TO_DATE(' 2012-09-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201208
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201209 values less than (TO_DATE(' 2012-10-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201209
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201210 values less than (TO_DATE(' 2012-11-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201210
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201211 values less than (TO_DATE(' 2012-12-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201211
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201212 values less than (TO_DATE(' 2013-01-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
          tablespace RTRN_PART_201212
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201301 values less than (TO_DATE(' 2013-02-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
          tablespace RTRN_PART_201301
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201302 values less than (TO_DATE(' 2013-03-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201302
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201303 values less than (TO_DATE(' 2013-04-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201303
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201304 values less than (TO_DATE(' 2013-05-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
       tablespace RTRN_PART_201304
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201305 values less than (TO_DATE(' 2013-06-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201305
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201306 values less than (TO_DATE(' 2013-07-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201306
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201307 values less than (TO_DATE(' 2013-08-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201307
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201308 values less than (TO_DATE(' 2013-09-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201308
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201309 values less than (TO_DATE(' 2013-10-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201309
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201310 values less than (TO_DATE(' 2013-11-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201310
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201311 values less than (TO_DATE(' 2013-12-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201311
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        ),
      partition PART_201312 values less than (TO_DATE(' 2014-01-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        tablespace RTRN_PART_201312
        pctfree 1
        initrans 1
        maxtrans 255
        storage
        (
          initial 8M
          next 1M
          minextents 1
          maxextents unlimited
        )
    )
    
    --COMPRESS --FOR OLTP
    as select *
    from retailer_transaction RT
    WHERE RT.DWH_NUM = 1441336376
    Published by: user5716448 on March 26, 2013 07:16

    >
    Fine regular table but challenging syntax below but tabel properties don't show no compression
    >
    What are properties? You have not shown any query or result that indicates if the table is compressed or not.
    >
    Now HSOING at the TABLE LEVEL or ON TABLE PORPETIES BUT WHEN check user_tab_partitions shows compressed for oltp
    >
    I don't know what all this means.

    New - you post anything indicating if the table is compressed or not. And without the DDL for the source table, no one can try to reproduce your results.

    Thanks for the use of tags code ad some of the necessary DOF but you edit your message and must REMOVE all definitions of extra partition since everything they do is inflate the list.

    It works for me 11.2.0.1.0 vanilla

    create table EMP_PART parallel
    COMPRESS FOR OLTP
    partition by range (hiredate)
    INTERVAL (NUMTOYMINTERVAL(1,'MONTH'))
    subpartition by hash (deptno)
    subPARTITIONS 4
    (
      partition all_data values less than (to_date('01/01/2013', 'mm/dd/yyyy')
    ))
    as select * from emp
    
    select table_name, compression, compress_for, composite, partition_name
    from user_tab_partitions
    
    TABLE_NAME     COMPRESSION     COMPRESS_FOR     COMPOSITE     PARTITION_NAME
    EMP_PART     ENABLED     OLTP     YES     ALL_DATA
    
  • create the 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 with beach-LIST table, and I get this error message, is the oracle 10.2.0.4 database supports to create the list range (composite) score


    {
    SQL > CREATE TABLE tbp_list_range
    (
    DATE OF REPORT_DATE,
    member_id_01 varchar2 (2),
    Date of DATE_SERVICE,
    member_id varchar2 (15)
    )
    PARTITION OF 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 on line 9:
    ORA-00922: missing or not valid 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
    AMT for Linux: release 10.2.0.4.0 - Production
    NLSRTL Version 10.2.0.4.0 - Production

    }

    Any help would be greatly appreciated.

    Thank you

    There are no ladders of partitioning in 10g either.

    Have a look here for partitioning methods: http://www.orafaq.com/wiki/Composite_partitioning

  • Oracle short 3.1 information discovery

    Hello

    I had to migrate from the old version of Oracle short in the new version. earlier, I have the short 7.5.1, server I had the backup of my data field of the command export. Now, I'm trying to import into the new Version of the Server 7.6 short. Before trying it, anyone?

    Coz m facing the error here The short server returned an error: OES-000169: could not connect to the server of short endeca2:7001.

    Please let me know if someone can help me

    Thank you

    Hi Olivier,.

    Try the following:

    Verify that your/etc/hosts is configured correctly. See information under the link host name resolution .

    Check that the syntax of the import command that you use is correct. See this doc: export and import a Data Domain

    When you import a data domain, server short matter its index in a new area of data it creates. This means that the short server must have a domain profile of valid data, it can use to create the new data field. He must also have sufficient resources on the system.

    It seems to me that the question is, however, the resolution of host name, so please check that first.

    Julia

  • On an oracle table partitioning. Please answer as soon as POSSIBLE.

    Hello

    I partitioned a table, but now I want to check whether or not the partition are created successfully. Can someone help me to know the way to find a partition table in the database?

    Regards,

    Rachid

    query these tables to find relevant information

    DBA_PART_TABLES

    ALL_PART_TABLES

    USER_PART_TABLES

    mark, if this can help

    Make sure you post in the right forum of next time

  • How can I define range partitions?

    Hi all

    In the physical model, I have a table defined as "Partitioned", activates the tab for partitioning. As a guy, I select "RANGE" so that the two tabs for 'Range interval Clause' and 'Order of Partitions' are active.

    My problem is now in the "Order of Partitions" tab. How can I create new entries in this window?
    Apparently, you can only edit existing ones, but not add new entries.

    Thanks for the tips.

    If you open the node of the Table there are Partitions inside node. Right click and choose "new".

  • Range partitioning

    I'm working on a problem and I hope to get some advice.
    Here's the question.

    Create a new table called SCOTT. A EMP_RANGE that contains the same columns as the table employee. The partition key is EMPNO column, and there should be five partitions, all located in the USERS area. Suppose EMPNO values start at one, reached 100 000 and are evenly distributed. Remember, EMPNO should be adjusted to contain 100000 records.

    First run this script:
    ALTER USER SCOTT
    DEFAULT TABLESPACE USERS
    10 M ON USERS QUOTA

    Then I created the table SCOTT. EMP_RANGE

    CREATE THE TABLE SCOTT. EMP_RANGE ".
    ('EMPNO' NUMBER (4,0),)
    'ENAME' NVARCHAR2 (20).
    VARCHAR2 (BYTE 9) "JOB."
    "MGR" NUMBER (4,0).
    "HIREDATE" DATE,
    "SALARY" NUMBER (7.2).
    NUMBER (7.2) "COMM"
    "DEPTNO" NUMBER (2.0).
    NVARCHAR2 (80) "EMP_ADDRESS."
    NUMBER (4,0) "EMPID"
    )

    PARTITION () RANGE (empno)
    partition e1 values less than users of tablespace (20000).
    partition e2 lower values that users tablespace (20000).
    partition e3 values less than users of tablespace (20000).
    partition e4 lower values that users tablespace (20000).
    E5 partition values less users tablespace (20000)
    );

    My question is, is this correct? Any help is greatly appreciated.

    Or adding the constraint of the right and the right upper limit:

    SQL> CREATE TABLE SCOTT.EMP_RANGE
      2  ( "EMPNO" NUMBER(6,0) check (empno <= 100000),
      3  "ENAME" NVARCHAR2(20),
      4  "JOB" VARCHAR2(9 BYTE),
      5  "MGR" NUMBER(4,0),
      6  "HIREDATE" DATE,
      7  "SALARY" NUMBER(7,2),
      8  "COMM" NUMBER(7,2),
      9  "DEPTNO" NUMBER(2,0),
     10  "EMP_ADDRESS" NVARCHAR2(80),
     11  "EMPID" NUMBER(4,0)
     12  )
     13  PARTITION BY RANGE(empno) (
     14  partition e1 values less than  (20000) tablespace users,
     15  partition e2 values less than  (40000) tablespace users,
     16  partition e3 values less than  (60000) tablespace users,
     17  partition e4 values less than ( 80000) tablespace users,
     18  partition e5 values less than (100001) tablespace users
     19  );
    
    Table created.
    
    SQL>
    
  • I rang microsoft to inform him that I received 2 phone calls today claiming to be them

    I received two phone calls today claiming to be from Microsoft saying that they have identified problems on my computer and trying to make me respond online. I called microsoft to let them know, and they put the phone clean on me! How can I inform Ms. this type of scam is underway and get them to warn users as was done in Australia in the summer 2010?

    Hi MartinMcCluney,

    These calls are false calls made by some offenders.

    Refer to the bottom of thread for more information on these calls.

    http://answers.Microsoft.com/en-us/Windows/Forum/windows_vista-security/i-received-a-phone-callemail-from-someone-saying/98a199f4-82cd-4433-b333-045451b89e2d

  • Partitioning the table - range on data type (21, 7) number and varchar2

    Hello

    Database version:

    DB: Oracle Database 11 g Enterprise Edition Release 11.2.0.3.0 - 64 bit Production

    Operating system: HP - UX nduhi18 B.11.31 U ia64 1022072414 unlimited-license user

    APP: SAP - ERP

    I have to the partition of the RANGE on UPDATED_ON or PROFILE is a table that has a structure below:

    Name Null?    Type

    -------------------- -------- --------------

    ------------------

    MANDT NOT NULL VARCHAR2 (9)

    MR_ID NOT NULL VARCHAR2 (60)

    PROFILE NON-NULL VARCHAR2 (54)

    NO_REGISTRE NOT NULL VARCHAR2 (30)

    INTERVAL_DATE NOT NULL VARCHAR2 (24)

    AGGR_CONSUMPTION NOT NULL NUMBER (21.6)

    MDM_VERS_NO NOT NULL VARCHAR2 (9)

    MDP_UPDATE_DATE NOT NULL VARCHAR2 (24)

    MDP_UPDATE_TIME NOT NULL VARCHAR2 (18)

    NMI_CONFIG NOT NULL VARCHAR2 (120)

    NMI_CONFIG_FLAG NOT NULL VARCHAR2 (3)

    MDM_DATA_STRM_ID NOT NULL VARCHAR2 (6)

    NSRD NOT NULL VARCHAR2 (24)

    REASON_CODE NOT NULL VARCHAR2 (9)

    QUALITY_FLAG NOT NULL VARCHAR2 (3)

    METHOD_FLAG NOT NULL VARCHAR2 (6)

    MSATS_UPDATE_DAT NOT NULL VARCHAR2 (24)

    MSATS_UPDATE_TIM NOT NULL VARCHAR2 (18)

    READ_STATUS NOT NULL VARCHAR2 (3)

    LEGACY_FLAG NOT NULL VARCHAR2 (3)

    CREATED_ON NOT NULL NUMBER (21.7)

    CREATED_BY NOT NULL VARCHAR2 (36)

    UPDATED_ON NOT NULL NUMBER (21.7)

    UPDATED_BY NOT NULL VARCHAR2 (36)

    CVERSNO NOT NULL VARCHAR2 (18)

    OLDER_MD_FLAG NOT NULL VARCHAR2 (3)

    TRANSACTION_ID NOT NULL VARCHAR2 (108)

    According to my knowledge, RANGE is better suited for the DATE or NUMBER. and partition INTERVAL is available on the DATE or number.

    PROFILE of column

    I havets is of type VARCHAR2. I know that again I can partition as Oracle convert internally to varchar2 in number when the data is inserted. But the INTERVAL is not possible.  However, so could you please suggest how RANGE partition on PROFILE?

    CREATED_ON column:

    It's the NUMBER with decimals. Could you guide me please?

    Please let me know if you need more information?

    See you soon

    Sameer

    I partitioned table as below:

    PARTITION BY RANGE

    (

    "CREATED_ON".

    )

    SUBPARTITION BY HASH

    (

    'PROFILE '.

    )

    SUBPARTITION TEMPLATE

    (

    TABLESPACE SUBPARTITION 'PROF_SUB01"'PSAPISU."

    TABLESPACE SUBPARTITION 'PROF_SUB02"'PSAPISU."

    TABLESPACE SUBPARTITION 'PROF_SUB03"'PSAPISU."

    TABLESPACE SUBPARTITION 'PROF_SUB04"'PSAPISU."

    TABLESPACE SUBPARTITION 'PROF_SUB05"'PSAPISU."

    TABLESPACE SUBPARTITION 'PROF_SUB06"'PSAPISU."

    TABLESPACE SUBPARTITION 'PROF_SUB07"'PSAPISU."

    TABLESPACE SUBPARTITION 'PROF_SUB08"'PSAPISU."

    TABLESPACE SUBPARTITION 'PROF_SUB09"'PSAPISU."

    TABLESPACE SUBPARTITION 'PROF_SUB10' 'PSAPISU '.

    )

    (

    "BEF12_CP00" VALUES LOWER PARTITION TO (20120101000000),

    "JAN12_CP01" VALUES LOWER PARTITION TO (20120201000000),

    "FEB12_CP02" VALUES LOWER PARTITION TO (20120301000000),

    "MAR12_CP03" VALUES LOWER PARTITION TO (20120401000000),

    "APR12_CP04" VALUES LOWER PARTITION TO (20120501000000),

    "MAY12_CP05" VALUES LOWER PARTITION TO (20120601000000),

    "JUN12_CP06" VALUES LOWER PARTITION TO (20120701000000),

    "JUL12_CP07" VALUES LOWER PARTITION TO (20120801000000),

    "AUG12_CP08" VALUES LOWER PARTITION TO (20120901000000),

    "SEP12_CP09" VALUES LOWER PARTITION TO (20121001000000),

    "OCT12_CP10" VALUES LOWER PARTITION TO (20121101000000),

    "NOV12_CP11" VALUES LOWER PARTITION TO (20121201000000),

    "DEC12_CP12" VALUES LOWER PARTITION TO (20130101000000),

    "JAN13_CP13" VALUES LOWER PARTITION TO (20130201000000),

    "FEB13_CP14" VALUES LOWER PARTITION TO (20130301000000),

    "MAR13_CP15" VALUES LOWER PARTITION TO (20130401000000),

    "APR13_CP16" VALUES LOWER PARTITION TO (20130501000000),

    "MAY13_CP17" VALUES LOWER PARTITION TO (20130601000000),

    "JUN13_CP18" VALUES LOWER PARTITION TO (20130701000000),

    "JUL13_CP19" VALUES LOWER PARTITION TO (20130801000000),

    "AUG13_CP20" VALUES LOWER PARTITION TO (20130901000000),

    "SEP13_CP21" VALUES LOWER PARTITION TO (20131001000000),

    "OCT13_CP22" VALUES LOWER PARTITION TO (20131101000000),

    "NOV13_CP23" VALUES LOWER PARTITION TO (20131201000000),

    PARTITION 'OTHER_CPMAX' VALUES LESS THAN (MAXVALUE)

    )

    works very well.

Maybe you are looking for