The Significance of Nested Data Storage over Flat File Database
The structuring of data in databases has shifted from the typical “flat” pattern of storage to nesting in recent years. While the traditional databases stored data in rows and tables, the nested databases that are much in vogue today, adopt a columnar pattern of data storage. ‘Nested data’ refers to a single or a group of variables that are associated with a particular group, and signifies an important observation pertaining to that group. Nested data structures bring advantages that are generally absent in a flat database system, which eventually reduces the storage cost associated with the model—an aspect crucial in areas like analytics and business intelligence. Further, nested data structures also improve query performance and reduce the number of rows containing duplicate data.
As a nested database stores the data in discrete columns within a single table, it reduces the number of large-scale joins required within the database. Consequently, the bottlenecks and performance issues resulting from large-scale joins are significantly reduced. Furthermore, the amount of pre-processing required to query the data in its natural form is also lowered considerably. Therefore, nested data simplifies modeling and storage decisions, besides improving querying performance.
However, the nested pattern of data storage is not without its share of drawbacks. For example, it is not in sync with the conventional form of web log data, and converting the nested format of data into a dimensional form can be quite time-consuming and tedious. Further, the dimensional data formats may also require additional queries, particularly in the event of a large number of join operations.