Google News
logo
SQL Server - Quiz(MCQ)
The basic syntax for using EXECUTE command is ________
A)
EXEC_SQL(@SQLStatement)
B)
EXECUTE(@SQLStatement)
C)
SP_EXECUTE(@SQLStatement)
D)
All of the above

Correct Answer :   EXECUTE(@SQLStatement)


Explanation :

EXECUTE command is demonstrated using :
SET @SQLQuery = 'SELECT * FROM tblEmployees
WHERE EmployeeID = ' + CAST(@EmpID AS NVARCHAR(10))
EXECUTE(@SQLQuery)

Advertisement