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

[Bug]: ManyToOneRelation.php always creates Nested Query #246

Open
cuca24 opened this issue Sep 22, 2023 · 0 comments
Open

[Bug]: ManyToOneRelation.php always creates Nested Query #246

cuca24 opened this issue Sep 22, 2023 · 0 comments

Comments

@cuca24
Copy link

cuca24 commented Sep 22, 2023

Expected behavior

Function getQueryPart of ManyToOneRelation.php should create BoolQuery instead of NestedQuery when allowInheritance on object is not selected (which is passed to $this->considerInheritance)

Otherwise any query on relation will result in es error "failed to create query: [nested] nested object under path [{fieldName}] is not of nested type"

Actual behavior

ManyToOneRelation.php always returns nestedQuery even when mapping is not nested (see function above)

Steps to reproduce

Create 2 objects. Put one object into relation to another object (without allow inheritance clicked on class definition). Index the object and try to use any filter according to the docs, README.md and it will faill with "failed to create query: [nested] nested object under path [{fieldName}] is not of nested type"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants