SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 SQL Server 2008 Forums
 Transact-SQL (2008)
 Working with Results from Remote Procedure Call
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Ambulare
Starting Member

8 Posts

Posted - 02/01/2013 :  09:05:46  Show Profile  Reply with Quote
Hi all,

I'm trying to import data resulting from a stored procedure on a linked server. I have admin rights on the local server but very limited permissions on the remote server as it's a commercial install managed by an external company, so I can't change any settings.

I can run the remote stored procedure call and it returns a result set, but any time I try to actually do anything with those results other than look at them on the screen, I get error messages. I can't put them in a table, table variable or a temp table, which pretty much makes the remote call useless as the result set can't be transformed or loaded.

Has anyone found a way around this?

James K
Flowing Fount of Yak Knowledge

3568 Posts

Posted - 02/01/2013 :  09:11:16  Show Profile  Reply with Quote
How are you trying to insert the data into a table? If it is a stored procedure, you would need to use something like the insert..exec command to grab the data from the stored procedure and insert into a table. Look at Sommarskog's article http://www.sommarskog.se/share_data.html

Another option is to use SSIS to import the data to your server.
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.03 seconds. Powered By: Snitz Forums 2000