| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> c.d.o.server -> Re: Import Assistance
Ste wrote:
> Hi,
>
> Question about ways of import:
>
> When I have exp.dmp from one db and import it into another db with
> different index tablespace, can I use sed or awk to change the index
> tablesapce name in the exp.dmp file, then import the data and index with
> proper index
> tablespace at the same time? Have anyone done it before?
>
> TIA,
> Ste
You can't muck around with the export file. It's not a text file, and editing it will corrupt it.
If you wish to change the tablespace into which objects get imported, there are a number of workarounds that Oracle supports.
For indexes, for example, you can run import with rows=n and indexes=n (so nothing actually gets imported) but with indexfile=name_of_file.txt ...that will cause import to generate a text file containing a script which, if run, will create all your indexes for you, from scratch. And since the indexfile *is* a text file, you can edit that to your heart's content, including changing the tablespace names. Once edited, you invoke it as you would any other SQL script -in SQL*Plus, using the "@" command.
Regards
HJR
Received on Sat Oct 04 2003 - 16:27:46 CDT
![]() |
![]() |