OPENJSON

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. 

2019-11-12 (first published: )

94 reads

Function and Queries to Convert Hierarchical Adjacency to Nested Json Arrays

  • Revision

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. 

2019-11-08

1 reads

Blogs

Azure Data Studeo- Nov 2019 Release

By

SQL Server Management studio is now can be installed separately not part of SQL...

Azure Synapse Analytics new features

By

Almost lost in all the announcements from Ignite was a bunch of amazing new...

Docker, Git and DBATools

By

For those who don’t know, last week was the PASS Summit. It’s an amazing...

Read the latest Blogs

Forums

I am looking to optimize this T-SQL Statement (it generates very High Reads..)

By VoldemarG

  In the below SQL statement (also attached as DOC file) it has been...

Computed Column Indexes

By Steve Jones - SSC Editor

Comments posted to this topic are about the item Computed Column Indexes

ASCII Text Dump

By saga

Comments posted to this topic are about the item ASCII Text Dump

Visit the forum

Ask SSC

SQL Server Q&A from the SQLServerCentral community

Get answers