Oracel import question

50 pts.
Tags:
Oracle
Oracle import/export
what happens if i import a particular table into a user schema which already contains the same table?
ASKED: May 6, 2008  6:11 AM
UPDATED: May 7, 2008  3:56 PM

Answer Wiki

Thanks. We'll let you know when a new response is added.

OK, it depends on a bunch of things….

If you did not choose to ignore errors on create, you will get an error message saying the table already exists and no rows will be imported.

If you chose to ignore errors and the tables are an exact match and with no primary key or unique indexes, the rows will be appended to the table. If there are unique indexes/primary keys enabled and any rows have common values, those will be rejected with ORA-000001. All other rows will be appended to the table.

If you chose to ignore errors and the existing table does not have the exact same columns and definitions, you will get an error for each row saying that the columns do not exist.

If the tables have the same column names, but the datatypes are not exact (differing lengths on varchar2 types or precision issues with number types) then import will load what rows it can and reject with an error any rows that it could not load.

Hope this helps…

Discuss This Question: 3  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • fartman
    Thks for the info meaning to say the data in the imported tables will not over-write the existing tables but is there a method to overwrite it if necessary? (a form of recovery if a particular table is corrupted)
    50 pointsBadges:
    report
  • Dwaltr
    Import will not directly write over a table that exists. You must drop it first in the database, then run the import.
    900 pointsBadges:
    report
  • Jcmdba
    Another option is to import the table to a different scheme (Oracle user) and then manually compare the table with the possible corrupted table. Rows and/or columns of data can be inserted/updated via sqlplus to get the "best" data.
    555 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following