dbTalk Databases Forums  

How to copy a db data

comp.databases.ingres comp.databases.ingres


Discuss How to copy a db data in the comp.databases.ingres forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Ingres Forums
 
Posts: n/a

Default How to copy a db data - 11-19-2009 , 08:14 AM






Hi,
Can someone let me know how to copy/move a ingres database including
the data from it's tables.

I used copydb, but it only copied the db schema (copy.in and copy.out),
not the data from the tables. This can be used only to create the same
db in other server. But, I want the data also to be copied.

Thanks,
Madhu.


--
madhukarmad84

Reply With Quote
  #2  
Old   
Ingres Forums
 
Posts: n/a

Default Re: How to copy a db data - 11-19-2009 , 08:32 AM






On the source machine:
c:
md work
cd work
copydb mydb
sql mydb < copy.out > out.log
find "E_" out.log

On the target machine:
c:
md work
cd work
copy \\sourcemachine\c$\work\*.*
createdb mydb
sql mydb < copy.in > in.log
find "E_" in.log


--
gerhard.hofmann (AT) planat (DOT) de
------------------------------------------------------------------------
gerhard.hofmann (AT) planat (DOT) de's Profile: http://community.ingres.com/forum/member.php?userid=857
View this thread: http://community.ingres.com/forum/sh...ad.php?t=11385

Reply With Quote
  #3  
Old   
Paul White
 
Posts: n/a

Default Re: [Info-Ingres] How to copy a db data - 11-19-2009 , 04:55 PM



for unloaddb:
In Unix it is unload.ing / reload.ing
In DOS is is unload.bat / reload.bat


If you are copying from one database to another on the same machine,
relocatedb is the fastest method, but it needs exclusive access to the DB.
100 times faster this way.
relocatedb olddata -newdatabase=newdata


If you need to transport the data between different versions of ingres,
different operating systems, I recommend copydb -c
Note that stored binary values usually cannot be moved in this way. eg
pictures, bitmaps, executables.
Beware of loss of floating point precision and date/time conversions. You'll
need to use the -fkxM.N parameter.
Watch out for character coding formats such as extended ascii and Unicode.
Ensure the destination server is using the same default date/time and
currency formats

But, if the machines on the same LAN, you should allow ingres net to take
care of the conversion between machine architectures, operating systems and
ingres versions. Also it handles date/time and other numeric conversions
ok. No need to manually copy the exported data. Binary data migrates
without a problem.


On the source machine:
Make sure all users disconnected from Ingres.

On the target machine:
run netutil
create vnode source, ip address, installation, user, password etc.
mkdir work
cd work
unloaddb source:lddata
unload.ing > out.log
grep "E_" out.log
createdb mydb
edit reload.ing to change the destination db
reload.ing > in.log
grep "E_" in.log



regards

Paul White


-----Original Message-----
From: info-ingres-bounces (AT) kettleriver...ting (DOT) com
[mailto:info-ingres-bounces (AT) kettleriverconsulting (DOT) com] On Behalf Of David
Stephens
Sent: Friday, 20 November 2009 12:57 AM
To: Ingres and related product discussion forum
Subject: Re: [Info-Ingres] How to copy a db data

Suggest using unloaddb if an exact copy of the database is required
(ie all user objects & system catalogs)


On the source machine:
c:
md work
cd work
unloaddb mydb
unload.ing > out.log
find "E_" out.log

On the target machine:
c:
md work
cd work
copy \\sourcemachine\c$\work\*.*
createdb mydb
reload.ing > in.log
find "E_" in.log

Regards,

Dave.

__________________________________________________ ____________

This message has been checked for all viruses by BTnet VirusScreen.
The service is delivered in partnership with MessageLabs and does not scan
any password protected or encrypted attachments.

Any views expressed in this message are those of the individual sender,
except where the sender specifically states them to be the views of the
company. The contents of this email are confidential to the addressee and
may also be privileged. If you are not the addressee of this email, you must
not copy, forward, disclose or otherwise use it, or any part of it, for any
purpose, nor disclose its contents to any other person. If you have received
this email in error please notify the sender. Please be aware that any
email sent to, or received from, this address may be monitored for quality
control, staff training or security purposes. Although the company scans all
outgoing email and attachments for viruses, neither the sender nor the
company accepts any responsibility for viruses and it remains the
responsibility of the recipient to scan email and attachments (if any) for
viruses.


_______________________________________________
Info-Ingres mailing list
Info-Ingres (AT) kettleriverconsulting (DOT) com
http://ext-cando.kettleriverconsulti...fo/info-ingres

Reply With Quote
  #4  
Old   
Ingres Forums
 
Posts: n/a

Default Re: How to copy a db data - 11-20-2009 , 03:53 AM



Thank you... Gerhard....


--
madhukarmad84

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.