SQL Flow Field Guide

@@LANGID

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
smallint

Syntax at a glance

@@LANGID

Work example

Inspect the current session language identifier while diagnosing date or message behavior.

Set required date parsing behavior explicitly instead of depending on a session's default language.

Check your work The language id belongs to the current session and is not a user preference store.

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