Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 Pulling Data from a Linked Server

Author  Topic 

funk.phenomena
Posting Yak Master

121 Posts

Posted - 2012-04-18 : 10:49:11
Hi All !!

I often pull data from a linked server, by using the following statement

SELECT * FROM OPENQUERY (servername, 'SELECT * FROM DATABASENAME.TABLENAME')

Is there any alternate ways you can write the code to pull the data?
THANKS!

webfred
Master Smack Fu Yak Hacker

8781 Posts

Posted - 2012-04-18 : 10:55:49
select * from LinkedServerName.DatabaseName.DBO.TableName


No, you're never too old to Yak'n'Roll if you're too young to die.
Go to Top of Page
   

- Advertisement -