Skip to content

Conversation

@fulghum
Copy link
Contributor

@fulghum fulghum commented Jun 6, 2025

Adds support for using UPDATE ... FROM statements to update a table using data joined from other tables.

The biggest gap I'm aware of is support for executing triggers on the updated table. GMS needs some additional changes to clean up the interface for plan.GetUpdatable() and needs to return implementations of sql.DatabaseSchemaTable in order for Doltgres triggers to work with UPDATE ... FROM statements.

Depends on: dolthub/go-mysql-server#3016

@github-actions
Copy link
Contributor

github-actions bot commented Jun 6, 2025

Main PR
covering_index_scan_postgres 327.57/s 338.97/s +3.4%
index_join_postgres 154.93/s 155.94/s +0.6%
index_join_scan_postgres 187.51/s 188.05/s +0.2%
index_scan_postgres 12.43/s 12.46/s +0.2%
oltp_point_select 2589.26/s 2508.90/s -3.2%
oltp_read_only 1868.59/s 1800.18/s -3.7%
select_random_points 117.88/s 117.97/s 0.0%
select_random_ranges 129.59/s 129.57/s -0.1%
table_scan_postgres 11.66/s 11.66/s 0.0%
types_table_scan_postgres 5.45/s 5.41/s -0.8%

@github-actions
Copy link
Contributor

github-actions bot commented Jun 6, 2025

Main PR
Total 42090 42090
Successful 16450 16450
Failures 25640 25640
Partial Successes1 5546 5546
Main PR
Successful 39.0829% 39.0829%
Failures 60.9171% 60.9171%

Footnotes

  1. These are tests that we're marking as Successful, however they do not match the expected output in some way. This is due to small differences, such as different wording on the error messages, or the column names being incorrect while the data itself is correct.

@fulghum fulghum force-pushed the fulghum/update_from branch 2 times, most recently from 674f2a4 to 2e00a30 Compare June 9, 2025 17:22
@fulghum fulghum force-pushed the fulghum/update_from branch 2 times, most recently from 1e2587a to 25e175a Compare June 9, 2025 21:33
@fulghum fulghum marked this pull request as ready for review June 9, 2025 21:35
@fulghum fulghum requested a review from zachmu June 9, 2025 21:54
Copy link
Member

@zachmu zachmu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, no notes

@fulghum fulghum force-pushed the fulghum/update_from branch from 25e175a to 66937b0 Compare June 10, 2025 19:25
@fulghum fulghum force-pushed the fulghum/update_from branch from 66937b0 to 49fd9f0 Compare June 10, 2025 19:31
@fulghum fulghum enabled auto-merge June 10, 2025 19:46
@fulghum fulghum merged commit f6dd664 into main Jun 10, 2025
14 checks passed
@fulghum fulghum deleted the fulghum/update_from branch June 10, 2025 20:34
@fulghum fulghum mentioned this pull request Aug 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants