APPLY

External Article

SQL Server CROSS APPLY and OUTER APPLY Helpful Examples

  • Article

Microsoft introduced the APPLY operator in SQL Server 2005. Similar to a JOIN, it allows correlation between two table expressions. The key difference between the JOIN and APPLY operators is when you have a table-valued expression on the right side and want to evaluate it for each row from the left table expression. Since they produce similar results, when do you choose an APPLY versus a JOIN?

2025-11-07

Technical Article

Function and Queries to Convert Hierarchical Adjacency to Nested Json Arrays

  • Script

This script converts hierarchical adjacency into nested json rows which contain the recursive "downlines" of each node.  The table-valued function treats each row in the original adjacency as the root node in a recursive common table expression. 

You rated this post out of 5. Change rating

2019-11-25 (first published: )

788 reads

Technical Article

Function and Queries to Convert Hierarchical Adjacency to Nested Json Arrays

  • Script

This script converts hierarchical adjacency into nested json rows which contain the recursive "downlines" of each node.  The table-valued function treats each row in the original adjacency as the root node in a recursive common table expression. 

You rated this post out of 5. Change rating

2019-11-12 (first published: )

2,066 reads

Blogs

RANK() vs DENSE_RANK(): #SQLNewBlogger

By

I haven’t done one of these in awhile, but I saw an article recently...

Using CAT for Testing of Data Agents

By

In last months one of the scenarios where you can use AI has been...

Read the latest Blogs

Forums

Missing the Jaro Winkler Distance

By Steve Jones - SSC Editor

Comments posted to this topic are about the item Missing the Jaro Winkler Distance

25 Years Later: What SQLServerCentral Meant to Me

By Brian Knight

Comments posted to this topic are about the item 25 Years Later: What SQLServerCentral...

Doing Good at SQL Server Central

By Steve Jones - SSC Editor

Comments posted to this topic are about the item Doing Good at SQL Server...

Visit the forum

Question of the Day

Missing the Jaro Winkler Distance

I upgraded a SQL Server 2019 instance to SQL Server 2025. I wanted to test the fuzzy string search functions. I run this code:

SELECT JARO_WINKLER_DISTANCE('tim', 'tom')
I get this error message:
Msg 195, Level 15, State 10, Line 1 'JARO_WINKLER_DISTANCE' is not a recognized built-in function name.
What is wrong?

See possible answers