how to code transerfering data from one database table to another when on different servers

Posted on 2011-10-07
Last Modified: 2013-11-30
I am unsure of how to code transferring data from one table in one database to another when on the same network but different server
INSERT INTO [acisql2].[dbo].[OPIS_LOGS]
FROM [JasperTest].[dbo].[OPIS_LOGS]

Open in new window

so how would I change the setup for the FROM ..... to connect to a different database on a different server
Question by:Tagom
    1 Comment
    LVL 4

    Accepted Solution

    You set up a linked (SQL) server with the management studio and assuming you have sufficient permissions on the remote server just use the four part syntax [OTHERSERVER].[OTHERDB].[dbo].[TABLE]

    But NOTE! If there are lots of rows in the remote table, that's a really slow way to do it. There are other ways such a bulk copy (BULK INSERT).

    Featured Post

    What Security Threats Are You Missing?

    Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

    Join & Write a Comment

    Everyone has problem when going to load data into Data warehouse (EDW). They all need to confirm that data quality is good but they don't no how to proceed. Microsoft has provided new task within SSIS 2008 called "Data Profiler Task". It solve th…
    Use this article to create a batch file to backup a Microsoft SQL Server database to a Windows folder.  The folder can be on the local hard drive or on a network share.  This batch file will query the SQL server to get the current date & time and wi…
    Using examples as well as descriptions, and references to Books Online, show the documentation available for date manipulation functions and by using a select few of these functions, show how date based data can be manipulated with these functions.
    This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

    734 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

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now