How should I delete the leaf node if the key in leaf node is also in some internal nodes?
@nanunsaram Жыл бұрын
Darn great!
@blockpaper10 ай бұрын
Didn't understand problem with duplicates in tree and how appending record_id solves it. Moreover, when I want to delete on 6, how I (DB systems) know what is record_id? I thought point of index is giving you record_id as a value so DB system can fetch tuple using record_id. When we use record_id as a part of a key what is the point of index then?
@Jael8606 ай бұрын
When you are doing a deletion, what you are actually doing is a deletion of a record from a table. Then in order to keep the index in sync with the table, you have to do a deletion on the index (the b+tree). Since you started by doing a deletion of a record, you know the record id, therefore you can compute the key needed to do the deletion in the B+tree.