Iterative Leaf Node Data Deletion for Interdependent Objects
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Existing database systems face challenges in efficiently deleting data from interdependent data objects due to referential integrity constraints, leading to performance overhead and the need for custom algorithms, which can result in complex and time-consuming solutions.
Innovation Solution
A data deletion process that iteratively identifies 'leaf nodes' in a graph representation of data objects, allowing for the deletion of data in chunks while checking for referential constraints, thereby reducing the duration of table locks and enabling parallel deletion operations.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If cascading delete is used to maintain referential integrity, then data consistency is improved, but performance overhead increases due to excessive locking and single-transaction deletion
Solution Approach 1:
The patent segments the deletion process into multiple independent transactions, each handling a subset of child records. Instead of deleting all child records in a single cascading transaction, the system divides the deletion into chunks, where each chunk is processed in a separate transaction. This segmentation reduces locking duration and allows parallel execution of deletion operations across multiple transactions, thereby improving performance while maintaining referential integrity through incremental deletion.
2Manufacturing precision
If custom algorithms are developed for specific deletion scenarios, then deletion accuracy is improved, but device complexity and development time increase
Solution Approach 1:
The patent implements a self-service mechanism where the database system automatically identifies child records with foreign key dependencies and processes them in the correct sequence without requiring custom algorithms. The system uses metadata about foreign key relationships to autonomously determine the deletion order, dividing work into manageable transactions that can be executed independently. This eliminates the need for scenario-specific custom code while maintaining accurate deletion behavior.
3Reliability
If all child records are deleted in a single transaction, then referential integrity is maintained, but locking duration increases and parallel processing is prevented
Solution Approach 1:
The patent applies segmentation by dividing the deletion of child records into multiple smaller transactions, each handling a portion of the total records. Each transaction maintains referential integrity for its subset of records while holding locks only for the duration necessary to complete that specific deletion chunk. This approach significantly reduces overall locking duration compared to a single large transaction, enabling other operations to proceed in parallel and improving system throughput.
4Reliability
If referential constraints are strictly enforced, then data quality is improved, but deletion operation complexity increases
Solution Approach 1:
The system employs a self-service approach where the database automatically manages referential constraint enforcement during deletion. By leveraging existing foreign key metadata and automated dependency detection, the system determines the correct deletion sequence without requiring complex manual algorithms. The referential constraints themselves guide the deletion process, with the database automatically identifying which child records depend on the parent record being deleted and processing them appropriately in incremental transactions.
Data Source
AI summary
Techniques and solutions are provided for identifying sets of related data, such as for a data deletion process. Data objects can be considered as having parent-child relationships, where values for one or more attributes of a child data object are constrained by corresponding one or more attributes of a parent data object. The set of data objects and their relationships can be represented, such as in a graph. In an iterative process, the data object representation is analyzed to identify “leaf nodes,” which are data objects that do not constrain other data objects. Relevant data is deleted from the data objects, and the representation is updated to “remove” such data objects so that a new set of leaf nodes is obtained. Optionally, when a leaf node that serves as a parent is analyzed, it can be confirmed whether corresponding data has already been deleted from its children.


