October 22, 2013 at 9:20 am
hello sorry i have post the last time empty by error but now this is my issue
i have a store procedure that return multiple datasets i want to manipulate one of theses datasets to input in a datatable is this posible and how
plese help me
October 23, 2013 at 1:37 pm
Well I had to put results from an SP into a table and here is how I did it:
DECLARE @rc int
INSERT INTO [Database].[dbo].Table_to_Insert_Into ( SP_Column1 , SP_Column2)
EXECUTE @rc = [Database].[dbo].[Sp_to_Run]
@Parameter
This is assuming the stored procedure returns two columns (1 or more rows) and Passing a parameter.
Hope this helps...
October 23, 2013 at 2:10 pm
Since you mention datatable, I assume you're using .NET?
Take a look at MARS (multiple active result sets):
Need an answer? No, you need a question
My blog at https://sqlkover.com.
MCSE Business Intelligence - Microsoft Data Platform MVP
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply