4/29/2023 0 Comments Hierarchical database example![]() ![]() In this article we will examine two models for dealing with hierarchical data in MySQL, starting with the traditional adjacency list model. These categories form a hierarchy in much the same way as the other examples cited above. ![]() For our purposes we will use the following product category hierarchy from an fictional electronics store: ![]() Hierarchical data can be found in a variety of database applications, including forum and mailing list threads, business organization charts, content management categories, and product categories. Hierarchical data has a parent-child relationship that is not naturally represented in a relational database table.įor our purposes, hierarchical data is a collection of data where each item has a single parent and zero or more children (with the exception of the root item, which has no parent). The tables of a relational database are not hierarchical (like XML), but are simply a flat list. Most users at one time or another have dealt with hierarchical data in a SQL database and no doubt learned that the management of hierarchical data is not what a relational database is intended for. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |