SQL Flow Field Guide

FROM table-valued function

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

inline TVF expands like a parameterized view; multi-statement TVF is a module filling a return table

What changes

Input
arguments (constants, variables, or outer columns under APPLY)
Output or change
rowset returned by the TVF

Syntax at a glance

FROM user_defined_function [ [ AS ] table_alias ]

Work example

A query needs FROM table-valued function to expose function output as a row source.

Start with one input value and name the output columns. Check returned types and row count before joining it to a larger source.

Check your work FROM table-valued function. The rowset from FROM table-valued function has the documented columns and one row per expected result.

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