-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
sql: extract k/v operations from insert/update/delete
Separates the mapping between table rows/indexes and key/values for the mutative operations. This will be useful immediately for implementing UPSERT and eventually for TableWriter. I tried to keep this as pure a refactor as I could, but it was a lot simpler to model an UPDATE with a PK change as a delete followed by an update (instead of migrating the mess I committed before). I'm still not clear which component decides which columns are required, but I think the additionally complexity that UPSERT/REPLACE adds will make it more obvious one way or another. Once that happens it should be more obvious how to handle all these colIDtoRowIndex maps.
- Loading branch information
Showing
4 changed files
with
644 additions
and
398 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.