SQL Flow Field Guide

ODBC scalar

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

ODBC scalar escape

What changes

Input
arguments in {fn ...} escape syntax
Output or change
scalar value

Syntax at a glance

SELECT {fn <function_name> [ (<argument>, ...n) ] }

Work example

Review scalar ODBC escape functions translated by a client driver.

Check translation through the actual ODBC driver and keep client syntax out of stored procedures.

Check your work Keep client escape syntax separate from stored T-SQL and verify the actual ODBC driver.

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