I have a stored procedure proc_abc
. In this stored procedure, I have few insert statements where I am calling other stored procedures and getting the results into temp tables, at the end of the stored procedure I return final results in a temp table #rset
.
Now when I use openquery
to run proc_abc
it returns the error
Msg 208, Level 16, State 1, Procedure '', Line 67
Invalid object name '#rset'.
Problem is I can not change the stored procedure, is there way to still be able to run it using openquery and get the stored procedures out put in my temp table?
Please guide.
Thanks