Click here to Skip to main content
14,639,057 members
Rate this:
Please Sign up or sign in to vote.
See more:
Hi guys,

I am trying to get SQL Store procedure value to temp table.Please help me

I tired below solutions that not fit to my requirement. If anyone know other then this solutions please let me know

1. I tried OPENROWSET here we need to give user id and password, so i don't need that.

2. In Store procedure writing INTO statement this is also not fit for my requirement


3. Creating a table and writing exec statement with store procedure this is not a solution for my problem, because columns are dynamic in count.
Posted
Comments
george4986 26-Sep-14 1:36am
   
post ur code here
syed shanu 26-Sep-14 1:48am
   
First Tell us clearly your requirement ,why you need stored procedure result in Temp Table.You can use temp table inside your SP.for example you do some select in Sp if you want to return that select result to temp table .You can do that in SP itself .if you tell us clearly about your requirement,your table details we can help you.
VishwaKL 26-Sep-14 1:51am
   
which store procedure i am using i dont have access to change, i need to get that result to temp table and query that again with some conditions.
PhilLenoir 26-Sep-14 10:03am
   
... then create a new stored proc, call the "fixed stored proc from that, declare a temp table, and push your result into that.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100