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

fix(db-postgres): error on delete having where that require joins #5459

Merged
merged 3 commits into from
Mar 26, 2024

Conversation

DanRibbens
Copy link
Contributor

@DanRibbens DanRibbens commented Mar 25, 2024

Description

When using deleteOne with a complex query, the join tables would not be included in the query.

This change reduces code duplication with a new function for postgres selectDistinct and calls it from deleteOne, update, and findMany.

  • I have read and understand the CONTRIBUTING.md document in this repository.

Type of change

  • Chore (non-breaking change which does not add functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Change to the templates directory (does not affect core functionality)
  • Change to the examples directory (does not affect core functionality)
  • This change requires a documentation update

Checklist:

  • I have added tests that prove my fix is effective or that my feature works
  • Existing test suite passes locally with my changes
  • I have made corresponding changes to the documentation

@DanRibbens DanRibbens changed the title chore(db-postgres): reduce duplicate lines of code fix(db-postgres): error on delete having where that require joins Mar 25, 2024
@DanRibbens DanRibbens merged commit 9169230 into main Mar 26, 2024
33 checks passed
@DanRibbens DanRibbens deleted the fix/postgres-deleteone branch March 26, 2024 18:00
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.

None yet

1 participant