You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -3176,7 +3180,10 @@ AND ca.utc_timestamp < @end_date';
3176
3180
INTO #pending_task_details
3177
3181
FROM #sp_server_diagnostics_component_result AS wi
3178
3182
CROSSAPPLYwi.sp_server_diagnostics_component_result.nodes('/event') AS w(x)
3179
-
CROSSAPPLYw.x.nodes('/event/data[@name="data"]/value/queryProcessing[@pendingTasks > 1]/pendingTasks/entryPoint') AS ep(e)
3183
+
/* Hardcoded threshold > 1 ignored the @pending_task_threshold
3184
+
parameter. Replaced with sql:variable() binding so the user's
3185
+
value actually takes effect here too. */
3186
+
CROSSAPPLYw.x.nodes('/event/data[@name="data"]/value/queryProcessing[@pendingTasks >= sql:variable("@pending_task_threshold")]/pendingTasks/entryPoint') AS ep(e)
0 commit comments