Scalar functions can hide row-by-row work in SQL Server; learn when inlining helps, how to inspect eligibility, and when a set-based rewrite wins.
SQL SERVER – Table Valued Functions – Day 26 of 35
Let us learn about table valued functions. Every day one winner from the United States will get Joes 2 Pros Volume 4.
AI_GENERATE_CHUNKS in SQL Server 2025: Splitting Long Text Into Pieces
AI_GENERATE_CHUNKS cuts one long piece of text into smaller pieces inside a query. This post tests the preview function on SQL Server 2025, shows what its columns hold and how overlap works, and explains how chunk size changes the number of pieces.
geometry STLength: A Path Is Longer Than Its Chord
geometry STLength measures the segments of a line. The example contrasts that path length with the shortest distance between its endpoints, including a closed line.
FOR XML XSINIL: Emit Missing Fields as Explicit Nil Elements
FOR XML XSINIL can represent SQL NULL with an explicit element carrying the xsi:nil attribute. I compare that output with ordinary element omission. An empty string stays a separate input in both versions.
XQuery Node Order: Compare Source Document Positions
XQuery node order compares positions in an XML document, not their text. Source order, alphabetical order and a node compared with itself give different answers.
geometry STAsBinary: Carry the SRID Beside the WKB
geometry STAsBinary exports a geometry as WKB, while reconstruction takes a separate spatial reference identifier. I carry that identifier beside the bytes. Supplying a different identifier creates a differently tagged value from the same exported coordinates.






