Tech or Treat! Write an article about your scariest tech disaster to win gadgets!Learn more

x
?
Solved

How to copy Table data from one database to another SQL

Posted on 2011-09-13
4
Medium Priority
?
303 Views
Last Modified: 2012-05-12
Hi.

Can you tell me how to copy table data from one database to another.

Each of database is on different Server.

Example:

I need to copy data from Table1 on   server1\sqlexpress to Table2 which is on server2\sqlexpress.

Databases are identical in structure.
I know how to copy with Microsoft SQL Managment studio Right click on database--> Export data. But i need code solution that will be executed from VB Program.

Thank you in advance.

P.S. I will never need old data from server2 so let's say that destination table will be empty.
0
Comment
Question by:Grogel
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 16

Expert Comment

by:Bryan Butler
ID: 36530239
0
 

Author Comment

by:Grogel
ID: 36530310
Is there some other way, simpler. Something like  insert (Select * from table1 on database1) into table2 on database2 - something like that?

I can load data in datagrid, and than insert row by row into another database but I was hoping for nicer solution.
0
 
LVL 16

Accepted Solution

by:
carsRST earned 2000 total points
ID: 36530325
0
 

Author Closing Comment

by:Grogel
ID: 36530407
Thank you.
0

Featured Post

NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Long way back, we had to take help from third party tools in order to encrypt and decrypt data.  Gradually Microsoft understood the need for this feature and started to implement it by building functionality into SQL Server. Finally, with SQL 2008, …
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
This course is ideal for IT System Administrators working with VMware vSphere and its associated products in their company infrastructure. This course teaches you how to install and maintain this virtualization technology to store data, prevent vuln…
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …

648 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question