I found lot of things very interesting on the website but not this one. I try to find an answer to my issue with OpenQuery, and I can't find it.
Let me explain, the goal for me is to query lot of SQL Servers in my compagny throught OPENQUERY & LINKED SERVER. Once my query is done, put the result into a table throught INSERT INTO.
Example :
INSERT into TABLE
select *
from openquery(LinkedServer,'SQLQuery')
Question 1 : How can I loop the LinkedServer ? to do the same but with others servers
Question 2 : How can I do my SQLQuery as a var on the query ?
Thanks a lot for your help