SQL Flow Field Guide

@@LOCK_TIMEOUT

Catalog support for SQL Server 2022 (16.x) and 2025 (17.x)

reads configuration (@@ function)

What changes

Input
server or session configuration state
Output or change
value
Return type
integer

Syntax at a glance

@@LOCK_TIMEOUT

Work example

Read the current session wait limit during a blocking investigation.

Read in the same session and compare before and after a controlled session setting change.

Check your work A value of negative one means an indefinite wait, so record it before interpreting a lock wait.

Open Microsoft Learn for full syntax, permissions, and details for your version.