-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Add Upsert/UpsertBatch to builder #6367
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
I'm working on a branch that combines this PR with #6373 and refactors everything. Putting it all together helps to better envision and combine things. Upsert shares some things with Insert and some with Update. When I get everything working combined I'll share so you guys can see this big picture. There are a few things with this PR and #6373 I think I'd like to rework a bit. One thing is how protectIdentifiers is applied and how that affects handling of arrays of constraints and update keys. I'd like them to be consistent in Insert/Upsert/Update batch methods. Then will use some common functions that will apply the protectIdentifiers. |
Can we agree that the primary purpose of methods like setInsertBatch, setUpdateBatch, or my proposed methods setBatch, is to enable collecting of data without executing. This might be in a loop such as reading data from a csv file and setting the data for batch insert. Other than that it might be used to get the sql statements without executing them. If the reason is this then we only need parameters needed setting the data.. the data itself and whether to escape or not. Things like batch size is not necessary information for setting the data. |
1f9f8f5
to
24344a1
Compare
24344a1
to
44832de
Compare
44832de
to
15f8b9f
Compare
15f8b9f
to
c099447
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR has only one commit.
The previous PR had more commits.
Please revert this PR to look like the commits in the previous PR.
Good job @sclubricants 👍 This feature will help me a lot 😃 |
This PR adds Upsert and UpsertBatch methods to builder.
This supersedes #6294
Checklist: