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

Proposal - Standardize @Subslect #698

Open
nexus061 opened this issue Jan 26, 2025 · 1 comment
Open

Proposal - Standardize @Subslect #698

nexus061 opened this issue Jan 26, 2025 · 1 comment

Comments

@nexus061
Copy link

Good morning everyone,
It would be interesting to standardize the behavior of Hibernate's @Subselect annotation. I was thinking of doing this through a dedicated annotation of this type:

@Documented @Retention(RUNTIME) @Target(ElementType.TYPE) public @interface VirtualEntity { String query(); boolean nativeQuery() default false; }

The idea is to specify a JPQL query as the default behavior, with the option to force it to a native query when necessary. What do you think?

@gavinking
Copy link
Contributor

Note that #393 is sorta related.

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