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(sql): Interpreters should add one join per relation at most #24

Merged
merged 2 commits into from
Jul 15, 2021

Conversation

ccatterina
Copy link
Contributor

If a condition specifies the same relation several times the interpreters should add the join statement only once.

Before this patch:

  • typeorm add a join statement for each condition that refers to the same relation.
  • sequelize doesn't include any relation because joins var was emptied during merge operation.

@stalniy
Copy link
Owner

stalniy commented Jul 15, 2021

Thanks for the fix but I think it was fixed in alpha branch, I used Set<string> to collect relation names

@stalniy stalniy changed the base branch from master to alpha July 15, 2021 09:04
If a condition specifies the same relation several times the
interpreters should add the join statement only once.
@stalniy
Copy link
Owner

stalniy commented Jul 15, 2021

anyway, thanks for the contribution! I adjusted it for alpha version and going to release a new version now

@stalniy stalniy merged commit d725e35 into stalniy:alpha Jul 15, 2021
@stalniy
Copy link
Owner

stalniy commented Jul 15, 2021

released in @ucast/sql@1.0.0-alpha.12

@ccatterina
Copy link
Contributor Author

Thanks for merging this!  😃

Next time I will start the PR from the alpha branch.

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.

2 participants