When I'm using the local server I can get a list of tables in my database like this:
SELECT * FROM MyDatabase.information_schema.TABLES
I can get a list of tables in the master like this:
SELECT * FROM master.information_schema.TABLES
I have a linked server named LinkSVR. There is a database named RemoteDB on the linked server.
To pull all the data from a table in RemoteDB, I can do this:
[tt]SELECT * FROM LinkSVR.RemoteDB.dbo.SomeTable[/tt]
So if that works, why wont this:
[tt]SELECT * FROM LinkSVR.RemoteDB.INFORMATION_SCHEMA.TABLES[/tt]
This following works, but of course it only shows tables in LinkSVR.master:
[tt]SELECT * FROM LinkSVR.master.INFORMATION_SCHEMA.TABLES[/tt]
How can I get a look at the tables in LinkSVR.RemoteDB ?
SELECT * FROM MyDatabase.information_schema.TABLES
I can get a list of tables in the master like this:
SELECT * FROM master.information_schema.TABLES
I have a linked server named LinkSVR. There is a database named RemoteDB on the linked server.
To pull all the data from a table in RemoteDB, I can do this:
[tt]SELECT * FROM LinkSVR.RemoteDB.dbo.SomeTable[/tt]
So if that works, why wont this:
[tt]SELECT * FROM LinkSVR.RemoteDB.INFORMATION_SCHEMA.TABLES[/tt]
This following works, but of course it only shows tables in LinkSVR.master:
[tt]SELECT * FROM LinkSVR.master.INFORMATION_SCHEMA.TABLES[/tt]
How can I get a look at the tables in LinkSVR.RemoteDB ?