Hi all
is there a simple command where I can just copy some data from one
database server to another?
For example, lets say i have two servers that have the same table
called "States"
If I have all the state names in server1 but want to copy the all the
data to Server2, how would I write a command for this?
INSERT INTO [server2].[database2].states
SELECT statename FROM [server1].[database1].states
I have tried this but it gives me an error saying
"Invalid object name [server1].[database1].states"
"Invalid object name [server2].[database2].states"
Do I need a use [database] somewhere?
thanks
Harry
is there a simple command where I can just copy some data from one
database server to another?
For example, lets say i have two servers that have the same table
called "States"
If I have all the state names in server1 but want to copy the all the
data to Server2, how would I write a command for this?
INSERT INTO [server2].[database2].states
SELECT statename FROM [server1].[database1].states
I have tried this but it gives me an error saying
"Invalid object name [server1].[database1].states"
"Invalid object name [server2].[database2].states"
Do I need a use [database] somewhere?
thanks
Harry
Comment