Skip to content

Fixed entity name retrieval for EntityProjection #1534

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

Merged
merged 4 commits into from
Jan 19, 2018

Conversation

bahusoid
Copy link
Member

@bahusoid bahusoid commented Jan 16, 2018

I've just realized that entity name should be retrieved from criteria instead of using _entityType.FullName. Otherwise queries with explicitly provided entity names won't work. I believe that existing tests in EntityProjectionsTest cover this change.

@fredericDelaporte
Copy link
Member

Otherwise queries with explicitly provided entity names won't work.

Having a test for them would then be great.

@bahusoid
Copy link
Member Author

bahusoid commented Jan 16, 2018

@fredericDelaporte Done. Yeah - writing a test is always a good idea :) It turns out that GetRootEntityTypeIfAvailable doesn't work for custom entity names. So type for root entity needs to be retrieved from persister.

Copy link
Member

@fredericDelaporte fredericDelaporte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It was lacking an async regeneration, I have pushed it.

@fredericDelaporte fredericDelaporte self-assigned this Jan 17, 2018
@fredericDelaporte fredericDelaporte merged commit f7dc55f into nhibernate:master Jan 19, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants