DBAsupport.com Forums - Powered by vBulletin
Results 1 to 9 of 9

Thread: Renaming Indexes & Constraints ????

  1. #1
    Join Date
    Jan 2001
    Posts
    642
    Hi,

    I want to shift from a big existing table (30 million records) non partitioned table to a partitioned table.

    I would like to get some suggesions as to how I can reduce the downtime during this process?
    Also, by rename the table , can I access the indexes created on that table again and

    Is it possible to rename the indexes and
    Is it possible to rename Foreign key references

    Please suggest,
    Badrinath

  2. #2
    Join Date
    Feb 2001
    Posts
    83
    Hi,

    By renaming a table, u can't use the index created before. U should create a new index for the newly named table.
    with regards
    Prasanna S

  3. #3
    Join Date
    Jan 2001
    Posts
    642

    RENAME CONSTRAINT/INDEX Attn:SReddy/Tamilselvan/Pando

    How about renaming the constraints and is there any way, I can just rename the table and still use the same index which was on the previous table.

    What If I don't recreate the index after renaming the table, can I use the earlier index

    How about using the previously created foreign key( Can I use them or Have to recreate the foreign keys also

    Badrinath

  4. #4
    Join Date
    Feb 2000
    Location
    Washington DC
    Posts
    1,843
    I don't think it will work as you are changing the base object, table name here in this case.

    I am afraid you might need to reload your data after DDL changes.
    Reddy,Sam

  5. #5
    Join Date
    Jan 2001
    Posts
    642
    hi Reddy,

    I had created a partitioned table, enabled constraints and also created the index on it.
    Later I have renamed the table and still I am able to see the same index and constraints attached to it,

    Is this correct, I am able to see all the constraints attached before with the same name.

    Please confirm
    Badrinath

  6. #6
    Join Date
    Feb 2000
    Location
    Washington DC
    Posts
    1,843
    I take back my previous posting. I have realized the fact what happens internally after discussion with my Manager who has been into Oracle from late 80's.

    This is how it works:

    Oracle internally treats and processes each object with ObjectID and not with the name. Name is for user convenience as its not possible to use objectID in replacement to Object name. Even if you say table xyz.t1 Oracle takes xyz.ObjectID_t1 for internal processing which makes sense and all the constraints will be valid. That what you have even after renaming the table.

    Hope this helps
    Reddy,Sam

  7. #7
    Join Date
    Jan 2001
    Posts
    642
    Hey,
    That was a perfect reply, Doubts about the constraints are clear., Is that the same with regards to indexes also
    Badrinath

  8. #8
    Join Date
    Feb 2000
    Location
    Washington DC
    Posts
    1,843
    I Guess that expalination holds good for even indexes too. You will be foine until DDL doesnt change. Just renaming makes not much different from this perspective you are talking about.
    Reddy,Sam

  9. #9
    Join Date
    Jan 2001
    Posts
    642
    I will test it an let you know,

    Thanks ones again

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width