Here Mudassar Ahmed Khan has explained with an example, how to return result value of EXEC function and save it to a variable in SQL Server.
The EXEC function supports returning value to a variable is supported in SQL Server versions i.e. 2000, 2005, 2008, 2008R2, 2012, 2014 or higher.
↧