Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Editing an Export (.dmp) file

Re: Editing an Export (.dmp) file

From: Matthew F. Reagan <mreagan_at_fast.net>
Date: 1997/12/09
Message-ID: <01bd045e$c104dc00$2890f5ce@laptopmr>#1/1

Gee, I haven't given this much thought in quite a while. Kevin Loney and I did a presentation on this at IOUW back in 91(?). In that presentation, we discussed the structure of an export file, and how to edit it.

We needed to do this to repair a corruption that occurred during export of a tablespace that had a fault in it. Export wrote a file without errors, we dropped the tablespace, and then tried to import. THAT is when IMP decided to tell us about the fatal bug.

This was back in V 6. The same format was used for V 7. I haven't tested V 8's export file format. Since Oracle developers (internal) are creatures of habit, they probably haven't changed it (just added on to it).

There is a length identifier at the beginning of each field in simple hex format. However, if you change the length of a field, you need to shift EVERY field and EVERY record that comes after it, or the import attempt will fail. We solved that problem by editing the varchar2 datatype at the end to either absorb the excess, or cough up a character or two, to make the record length stay the same.

This is not a really smart way to do what you are looking for, tho. It is a MAJOR pain in the butt. We used it to recover data that was otherwise lost. The other posting on this question has better options to look into.

Good luck, in whatever you choose to do.

Matt...

sarab_at_pop.jaring.my wrote in article
<01bd03e6$f0366520$ee03a8c0_at_W238SRS.ac.com>...
> Hi folks,
>
> I know that Oracle Corp. does not support this, but has anybody had any
> success editing the contents of an export file.
> My goal is to replace the data value of a column on all the tables of the
> export file. All my tables have this column called "user" and denotes
 which
> user this data belongs to. What I'm trying to accomplish is to duplicate
> data for other users in our database by changing this value in the export
> file. A couple of years ago I tried to edit an export file and learnt the
> hard way that we are not supposed to as there are hidden control
 characters
> in the header of the file (or so I was told in the Oracle course that I
> attended). I am hoping to use an editor like vi to replace the column
 value
> for all my data in the export file.
> Anybody ever succeeded doing something like this. Would love to hear from
> you.
>
> Regards
>
  Received on Tue Dec 09 1997 - 00:00:00 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US