Skip to content
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

Refactor ReaderModificationCommandBatch #27583

Closed
roji opened this issue Mar 7, 2022 · 0 comments
Closed

Refactor ReaderModificationCommandBatch #27583

roji opened this issue Mar 7, 2022 · 0 comments
Assignees
Labels
area-save-changes closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. type-enhancement
Milestone

Comments

@roji
Copy link
Member

roji commented Mar 7, 2022

As discussed offline with @AndriySvyryd, ReaderModificationCommandBatch currently adds a parameter for each IColumnModification, for each modification command - in order. This makes it difficult to implement patterns which do fancy things with parameters. For example, on PostgreSQL insertion of multiple rows can be optimized as follows:

INSERT INTO data_table (id, name) SELECT * FROM unnest(@i, @n)

Where @i and @n are array for the column values of the different rows.

In addition, I think we can simplify the current design and apply commands to the batch directly as they're added, as opposed to the current CachedCommandText mechanism.

@roji roji self-assigned this Mar 7, 2022
roji added a commit to roji/efcore that referenced this issue Mar 7, 2022
* Allow flexible/alternative parameter strategies
* Insert commands and update SQL immediately

Closes dotnet#27583
@ajcvickers ajcvickers added this to the 7.0.0 milestone Mar 9, 2022
roji added a commit to roji/efcore that referenced this issue Mar 14, 2022
* Allow flexible/alternative parameter strategies
* Insert commands and update SQL immediately

Closes dotnet#27583
roji added a commit to roji/efcore that referenced this issue Mar 14, 2022
* Allow flexible/alternative parameter strategies
* Insert commands and update SQL immediately

Closes dotnet#27583
roji added a commit to roji/efcore that referenced this issue Mar 17, 2022
* Allow flexible/alternative parameter strategies
* Insert commands and update SQL immediately

Closes dotnet#27583
roji added a commit to roji/efcore that referenced this issue Mar 17, 2022
* Allow flexible/alternative parameter strategies
* Insert commands and update SQL immediately

Closes dotnet#27583
roji added a commit to roji/efcore that referenced this issue Mar 17, 2022
* Allow flexible/alternative parameter strategies
* Insert commands and update SQL immediately

Closes dotnet#27583
roji added a commit to roji/efcore that referenced this issue Mar 18, 2022
* Allow flexible/alternative parameter strategies
* Insert commands and update SQL immediately

Closes dotnet#27583
roji added a commit to roji/efcore that referenced this issue Mar 18, 2022
* Allow flexible/alternative parameter strategies
* Insert commands and update SQL immediately

Closes dotnet#27583
@ghost ghost closed this as completed in 44f1c24 Mar 18, 2022
@ajcvickers ajcvickers added the closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. label Mar 31, 2022
@ajcvickers ajcvickers modified the milestones: 7.0.0, 7.0.0-preview3 Mar 31, 2022
@ajcvickers ajcvickers modified the milestones: 7.0.0-preview3, 7.0.0 Nov 5, 2022
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-save-changes closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. type-enhancement
Projects
None yet
Development

No branches or pull requests

2 participants