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

JoinConditions inside container and connector conditions #72

Open
FrancoLiberali opened this issue Aug 29, 2023 · 0 comments
Open

JoinConditions inside container and connector conditions #72

FrancoLiberali opened this issue Aug 29, 2023 · 0 comments

Comments

@FrancoLiberali
Copy link

orm.And(), orm.Or() and orm.Not() only support WhereConditions inside, making it imposible to do
orm.Or(
attribute = "something",
relation.attribute == "something",
)

In order to do that, the join must be transformed in a EXISTS.
Once done, WhereCondition can be deleted and orm.NewQuery will not need to put the model as generic type.
It means also changing the way preloads are done, because we can not do a preload from a EXISTS. Maybe the preloads should be done on JoinConditions and not with methods of the condition model

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

No branches or pull requests

1 participant