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

Property map nested association throws exception when key matches part of the property path. #129

Open
basven opened this issue Oct 24, 2023 · 1 comment

Comments

@basven
Copy link

basven commented Oct 24, 2023

Not sure if this is considered a bug or maybe a documentation update.
I can successfully filter on a.b.c=='some value'.
where a is a manytoOne from the root to 'a' and 'b' is a manytoOne from a to b like this:

`
public class Root{
@manytoone(optional = false, fetch = FetchType.LAZY)
private A a;
}

public class A{
@manytoone(optional = false, fetch = FetchType.LAZY)
private B b;
}

public class B{
private int C;
}
`

When I put that in a property map however I get the following exception:
Unknown property: c from entity A
when the key of the property matches (part of) the property path. In my case I defined it as
put('b', 'a.b.c')

If I change that to something like:
put('myProperty', 'a.b.c')
it works just fine.

I was under the impression that the key part could be any string.

@basven basven changed the title Property map nested association throws exception Property map nested association throws exception when key matches part of the property path. Oct 24, 2023
@perplexhub
Copy link
Owner

Does Root have an attribute named b?

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

2 participants