When you use EXEC statement, behind the scenes, three system internal stored procedures: sp_prepexec, sp_execute, and sp_unprepare are called
From the name, you can tell that sp_prepexec is used to prepare dynamic SQL on the server, which speeds up subsequent executions of the same statement ---------------------------- 当使用EXEC,后台有三个永久的存储过程(sp_prepexec, sp_execute,sp_unprepare)被调用。从名字上可以看出,sp_prepexec 被用来在服务器上作为动态SQL运行的准备工作,它可以加速相同语句的并发执行。
From the name, you can tell that sp_prepexec is used to prepare dynamic SQL on the server, which speeds up subsequent executions of the same statement ----------------------------
当使用EXEC,后台有三个永久的存储过程(sp_prepexec, sp_execute,sp_unprepare)被调用。从名字上可以看出,sp_prepexec 被用来在服务器上作为动态SQL运行的准备工作,它可以加速相同语句的并发执行。