Translating with DrWatson… this can take a few seconds the first time.
This is a genuine, complex translation. DrWatson protects commands, error codes, and log output while naturally translating the surrounding text. It’s translated once and saved.
Larry Sorensen (IDS 11.50.FC5) asked for an easy way to copy a database to a new name in the same instance. Kern Doe suggested onunload/onload unless external tables, UDTs or dbspace locations matter. Art Kagel suggested dbexport then dbimport under another name, or dbschema plus a table-by-table copy script. David Grove noted onunload/onload fails with blobs.
Auto-generated by Claude from the posts below — may be imperfect; read the full thread.
Solaris 10
IDS 11.50.FC5
I am looking for an easy way to make a copy of a database in the same
instance, but with a different name. Any suggestions?
Larry
Larry,If your database does not have external tables or user defined data
types or you don't care much about the original locations (dbspaces) of tables
and indexes, you may use "onunload/onload".Kern -- Let's go GreenThis email
contains 100% recycled electrons.
From: LARRY SORENSEN <LSORENSEN25@msn.com>
To: ids@iiug.org
Sent: Thursday, February 2, 2017 2:36 PM
Subject: database copy [38585]
Solaris 10
IDS 11.50.FC5
I am looking for an easy way to make a copy of a database in the same
instance, but with a different name. Any suggestions?
Larry
*******************************************************************************
Forum Note: Use "Reply" to post a response in the discussion forum.
1. dbexport then dbimport to a different database name
2. dbschema -ss or myschema to get a schema and use that to create the
new database, then use my dbscript utility to create a data copy script for
all tables. Here's an example using my dbmove utility to do the actual
copy, but you could replace that with call to a shell script that opens
dbaccess and just does "insert into target:<table> select * from
source:<table>;" taking hte table name on the command line:
dbscript -d sourcedb -c 'dbmove -d sourcedb -D targetdb -t %s\\
'
>copy_script.sh
Art
Art S. Kagel, President and Principal Consultant
ASK Database Management
www.askdbmgt.com
Blog: http://informix-myview.blogspot.com/
Disclaimer: Please keep in mind that my own opinions are my own opinions
and do not reflect on the IIUG, nor any other organization with which I am
associated either explicitly, implicitly, or by inference. Neither do
those opinions reflect those of other individuals affiliated with any
entity with which I am affiliated nor those of the entities themselves.
On Thu, Feb 2, 2017 at 2:36 PM, LARRY SORENSEN <LSORENSEN25@msn.com> wrote:
> Solaris 10
>
> IDS 11.50.FC5
>
> I am looking for an easy way to make a copy of a database in the same
> instance, but with a different name. Any suggestions?
>
> Larry
>
>
> ************************************************************
> *******************
> Forum Note: Use "Reply" to post a response in the discussion forum.
>
>
--001a114b327acea8220547919bd4
↪ replying to Kern Doe
DAVID GROVE — — source: IIUG Forums & Mailing Lists
Also can't use onunload/onload if you have blobs.
DG
Your privacy choices
We use strictly necessary cookies to make this site work. With your
consent we’d also use optional cookies for analytics and marketing. You can accept all,
reject all, or choose. Read our Cookie Policy.