t-sql help - stored procedure call anther stored procedure
Posted on 2013-02-05
I need help on #2 and #3:
1) select data from a table, stored the STD_ID in the temp table.
2) need to execute anther stored procedure 'GET_STD_INFO ' pass in the STD_ID, it will return columns included the following:
STD_ID, STD_NAME, ACTIVE_IND AND CLASSES_TOTAL, etc...
3) need to update the temp table with the return columns of STD_ID, STD_NAME, ACTIVE_IND AND CLASSES_TOTAL
DECLARE @TMP_TEST table
TOP 1 STD_ID
ORDER BY ACTIVE_YEAR
what is the best way to do this?
I am running in MS SQL server 2010.