O'Reilly logo

SQL Server MVP Deep Dives Vol. 2 by Kimberly Tripp, Paul Randal, Paul Nielsen, Brad McGehee, Greg Low, Louis Davidson, Kalen Delaney

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 29. Effective use of HierarchyId

Denis Reznik

We find hierarchies in many places in our lives, such as organizational structures, sporting events, product categories in an e-market, social relationships, algorithms, classifications, and elsewhere. Modeling such systems means creating and storing information about the objects in a system. Tons of code was written using object-oriented programming principles, and many variants of storing information about objects in a database were invented. Hierarchy is a type of relationship between objects, and that’s why modeling hierarchies is a common operation in writing code and databases.

Hierarchies in a database

There are many types of hierarchy implementations in a database. Parent-child ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required