diff --git a/tooling/metamodel-generator/src/main/java/org/hibernate/processor/annotation/AnnotationMeta.java b/tooling/metamodel-generator/src/main/java/org/hibernate/processor/annotation/AnnotationMeta.java index e053a1834f..8a54dec99c 100644 --- a/tooling/metamodel-generator/src/main/java/org/hibernate/processor/annotation/AnnotationMeta.java +++ b/tooling/metamodel-generator/src/main/java/org/hibernate/processor/annotation/AnnotationMeta.java @@ -105,10 +105,11 @@ public abstract class AnnotationMeta implements Metamodel { context.getEntityNameMappings(), context.getEnumTypesByValue() ) ); if ( statement instanceof SqmSelectStatement - && isQueryMethodName( name ) ) { + && isQueryMethodName( name ) + && !isJakartaDataStyle() ) { putMember( name, // TODO: respect @NamedQuery(resultClass) - new NamedQueryMethod( + new NamedQueryMethod( this, (SqmSelectStatement) statement, name.substring(1),