Re: dbexport/dbimport w/ new db name
Posted in 1995
In <45488g$27a$1@mhadf.production.compuserve.com> Patrick Soehl
<102121.3564@CompuServe.COM> writes:
>
>I'm trying to export/import a db and rename it...What I'm trying
>to accomplish is to make a copy (eventually several copies).
>
>1) dbexport -o /usr2/informix mumble1
>
>This creates a mumble1.exp
>
>If I use another instance, I can get
>
>dbimport mumble1 to work just fine.
>
>dbimport -i /usr2/informix mumcopy
>dbimport -i /usr2/informix/mumble1.exp mumcopy>
>Both give me
>"Cannot open sql script file"
>
>Now, according to the "OnLine Administrator's Guide, v5.0"
>p7-9 "You can give the database a new name if you use the
>-i option". Of course, it doesn't give an example of how to
>do that. I've even made a copy of the the mumble1.sql file and
>modified it to create database mumcopy and I still get the same
>message.
>I sure would appreciate some help. TIA.. pnsoehl
>OnLine 5.05.uc2, AIX 3.2.5
>
>--
>No opinions, just FAX!
>Uhh... I mean FACTS!
Patrick:
I'm not sure this is what you have in mind,but you can create a
different database from a dbexport. It's a thee step process:
After creating the mumblel database with dbexport:
rename mumblel.exp to newmumblel.exp
change to the newmumblel.exp directory and rename the mumblel.sql
script to newmumblel.sql
edit the newmumble script and change the database statement to create
newmumblel instead of mumblel.
Now, perform your dbimport:
dbimport newmumblel -i .....
hope this is of help!
regards,
ed
schaefer