Can we create the Partition on Existing Table?

  • Can we create the Partition on Existing Table?

    e.g Create table t ( col1 number(10,0), Col2 Varchar(10)) ;

    After the table Creation can we alter the table to partition the table.

  • Yes you can. But before that, you should do some research: is col1 ever-increasing, how many records will be in one partition, min, max values for each partition, can col1 be clustered index? And the most important think is what is the purpose to partition this particular table? Archiving, data load, setting old partitions to read-only to minimize impact of database maintenance? What your FG, files mapping will look like?

  • nilesh_dalvi (3/4/2015)


    Can we create the Partition on Existing Table?

    e.g Create table t ( col1 number(10,0), Col2 Varchar(10)) ;

    After the table Creation can we alter the table to partition the table.

    The biggest things to ask here is 1) what is the table used for (for example, is the "old" data in the table totally static like you mind find in an audit table) and 2) why do you want to partition it?

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply