在 SQL Server Profiler 集合中,會記錄事件 SP:CacheInsert ,而不是事件 SP:Recompile。 Transact-SQL 語法慣例 語法 syntaxsql 複製 sp_recompile [ @objname = ] N'object' [ ; ] 引數 [ @objname = ] N'object' 目前資料庫中預存程式、觸發程式、數據表、檢視或使用者定義函數的限定或...
sp_recompile sp_refreshsqlmodule sp_refreshview sp_releaseapplock sp_rename sp_renamedb sp_resetstatus(重置状态命令) sp_rxpredict 获取序列范围 sp_server_diagnostics sp_set_session_context(设置会话上下文的存储过程) sp_setnetname sp_settriggerorder ...
在sqlserver中,有一个系统存储过程:sp_recompile,可以强制对访问recompile【存储过程、触发器、表、视图】进行访问的相关的sql语句进行重新编译执行计划! 如果object是存储过程或触发器的名称,那么该存储过程或触发器将在下次运行时重新编译。如果object是表或视图的名称,那么所有引用该表或视图的存储过程都将在下次运行...
In SQL Server, a recompile is a process where the query optimizer generates a new execution plan for a stored procedure or a batch of SQL statements. This article explains the concept of recompilation in SQL Server, when it is necessary, and how to use it effectively in your database app...
sp_recompile (Transact-SQL) 使存储过程和触发器在下次运行时重新编译。具体方法是:从过程缓存中删除现有计划,强制在下次运行该过程或触发器时创建新计划。在 SQL Server Profiler 集合中,记录事件 SP:CacheInsert 而不是事件 SP:Recompile。 Transact-SQL 语法约定 ...
SP:Recompile Event Class Data ColumnsRozbaliť tabuľku Data column nameData typeDescriptionColumn IDFilterable ApplicationName nvarchar Name of the client application that created the connection to an instance of Microsoft SQL Server. This column is populated with the values passed by the ...
The preferred way to trace statement-level recompilations is to use the SQL:StmtRecompile event class. The SP:Recompile event class is deprecated. For more information, see SQL:StmtRecompile Event Class.SP:Recompile Event Class Data Columns...
This article describes how to recompile a stored procedure in SQL Server by using Transact-SQL. There are three ways to do this:WITH RECOMPILEoption in the procedure definition or when the procedure is called, the RECOMPILE query hint on individual statements, or by using thesp_recompilesyste...
This article describes how to recompile a stored procedure in SQL Server by using Transact-SQL. There are three ways to do this: WITH RECOMPILE option in the procedure definition or when the procedure is called, the RECOMPILE query hint on individual statements, or by using the sp_recompile...
OPTION(RECOMPILE)会大大提高带参数的执行计划、sql语句 加OPTION(RECOMPILE),可以使执行计划重新编译,提高性能。 sql MVP 原文:http://www.cnblogs.com/CareySon/archive/2013/05/04/PlanCacheInSQLServer.html 谈一谈SQL Server中的执行计划缓存(上)