Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4102520
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T20:50:16+00:00 2026-05-20T20:50:16+00:00

I have a specific scenario where i have to insert two new columns in

  • 0

I have a specific scenario where i have to insert two new columns in an existing table in Oracle. I can not do the dropping and recreating the table. So can it be achieved by any means??

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T20:50:16+00:00Added an answer on May 20, 2026 at 8:50 pm

    Amit-

    I don’t believe you can add a column anywhere but at the end of the table once the table is created. One solution might be to try this:

    CREATE TABLE MY_TEMP_TABLE AS
    SELECT *
    FROM TABLE_TO_CHANGE;
    

    Drop the table you want to add columns to:

    DROP TABLE TABLE_TO_CHANGE;
    

    It’s at the point you could rebuild the existing table from scratch adding in the columns where you wish.
    Let’s assume for this exercise you want to add the columns named “COL2 and COL3”.

    Now insert the data back into the new table:

    INSERT INTO TABLE_TO_CHANGE (COL1, COL2, COL3, COL4) 
    SELECT COL1, 'Foo', 'Bar', COL4
    FROM MY_TEMP_TABLE;
    

    When the data is inserted into your “new-old” table, you can drop the temp table.

    DROP TABLE MY_TEMP_TABLE;
    

    This is often what I do when I want to add columns in a specific location. Obviously if this is a production on-line system, then it’s probably not practical, but just one potential idea.

    -CJ

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This is a more theoretical question, not a specific scenario: Let's assume, we have
Here's my scenario: I have a simple stored procedure that removes a specific set
I have a very specific html table construct that seems to reveal a Gecko
I have the problem that an specific step in Ant can only be executed
We have a database with a very simple schema: CREATE TABLE IF NOT EXISTS
I have a bit of an odd scenario where I have a table that
i have this specific scenario: i have 4 tabs and each tab has it's
I have a specific changeset that I want to rollback my Development branch to,
The only SET parameter that I have found specific guidance for is SET TRANSACTION
I'd like to copy the files that have a specific file extension to a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.