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

Replace calls to seq by adding a RETURNING * to all insert and replace statements #101

Merged
merged 10 commits into from
Feb 29, 2024

Conversation

mattbucci
Copy link
Collaborator

@mattbucci mattbucci commented Feb 22, 2024

Closes:

This PR appends RETURNING * to all insert queries so that wpsqli_insert_id can check for a primary key on the table that was last inserted against and grab the last inserted value in a more robust way, especially for tables without sequences.

  • Removes of noop logic for term_relationships
  • Removes custom logic for handling post_author insertion

@mattbucci mattbucci force-pushed the returning-replaces-seq branch from 2aaf030 to 8d420dc Compare February 22, 2024 04:22
@mattbucci mattbucci changed the title WIP: replace calls to seq by adding a RETURNING * to all insert statements Replace calls to seq by adding a RETURNING * to all insert and replace statements Feb 27, 2024
@mattbucci mattbucci marked this pull request as ready for review February 27, 2024 07:34
@mattbucci mattbucci merged commit c7e3fbd into v3 Feb 29, 2024
1 check passed
@mattbucci mattbucci deleted the returning-replaces-seq branch February 29, 2024 08:08
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.

1 participant