Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Move tables from one server to another

Status
Not open for further replies.

dbinfoweb

Technical User
Nov 20, 2001
59
US
Hello,
I have never done this before. I am just wondering how I can move a few tables I have from one Sybase server to another Sybase server, thanks for any help in advance.
 
I will do:
- create the same table on the new server
- bcp out the data of the table on the old server
- bcp in the data to the new server

However I don't know if there is any precausion between 2 different version of Sybase, and what is the impact if your table is really big. You need to consult with others.

Babeo
 
Just to add a couple of notes, if you have Sybase Central, it should be able to create a script for you to recreate your tables on the target server.

Also, if your two Sybase servers are different hardware platforms, you will want to BCP out the data in character mode -c. Be sure to let BCP create a format file for you and give it a name that matches your table so that you can use the format file when you put the data back into the other server. If you've got two instances of the same server hardware involved (or are moving between two DB's on the same instance of Sybase), then use -n (native mode) with BCP.

If your tables are big, I'd recommend using a batch size no bigger than say 500 rows on the BCP IN and set the DB to truncate its transaction log on checkpoint. Turn off log truncation and do a full backup of the target DB when all the data's in.

Best of luck,

John J M Craig
Alpha-G Consulting, LLC
nsjmcraig@netscape.net
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top