Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Data Bases > Microsoft SQL Server > Re: Doing a SEL...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 3 of 4 Topic 11032 of 11517
Post > Topic >>

Re: Doing a SELECT INTO using a Stored Proc as the data source

by "Plamen Ratchev" <Plamen@[EMAIL PROTECTED] > May 11, 2008 at 09:46 AM

You can use OPENQUERY, like:

SELECT * INTO #Tmp FROM OPENQUERY(Loopback, 'EXEC MySp');

Make sure to read Erland Sommarskog's article on some issues with this 
approach:
http://www.sommarskog.se/share_data.html#OPENQUERY

Also, if you create the table structure first then you can use INSERT
EXEC:

INSERT #Tmp EXEC MySp;

HTH,

Plamen Ratchev
http://www.SQLStudio.com
 




 4 Posts in Topic:
Doing a SELECT INTO using a Stored Proc as the data source
Deane <deane.barker@[E  2008-05-10 20:29:14 
Re: Doing a SELECT INTO using a Stored Proc as the data source
Tom van Stiphout <no.s  2008-05-10 21:02:10 
Re: Doing a SELECT INTO using a Stored Proc as the data source
"Plamen Ratchev"  2008-05-11 09:46:43 
Re: Doing a SELECT INTO using a Stored Proc as the data source
Deane <deane.barker@[E  2008-05-12 06:34:09 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Wed Dec 3 1:12:12 CST 2008.