I have two databases, both on the same server the default is named XXX
the second is XXX\MSSQKSERVERVIS7
I need to copy a table from the second db to the default. When I attempt to use the server name I get an error that the \ is incorrect syntax. The query is quite simple I run the query from the default instance
SELECT *
INTO table
FROM XXX\MSSQLSERVERVIS7.[db].[dbo].[table]
If I put brackets around the server name I get the error that the object doesn't exist.