hibernate/hibernate-orm · error · IllegalArgumentException
Illegal frame kind: {child}
Error message
Illegal frame kind: {child} What it means
Error "Illegal frame kind: {child}" thrown in hibernate/hibernate-orm.
Source
Thrown at hibernate-core/src/main/java/org/hibernate/query/hql/internal/SemanticQueryBuilder.java:5443
endKind,
endExpression,
exclusion
);
}
private FrameKind getFrameKind(ParseTree child) {
final var symbol = ((TerminalNode) child.getChild( 1 )).getSymbol();
return switch ( symbol.getType() ) {
case HqlParser.PRECEDING ->
child.getChild( 0 ) instanceof TerminalNode
? FrameKind.UNBOUNDED_PRECEDING
: FrameKind.OFFSET_PRECEDING;
case HqlParser.FOLLOWING ->
child.getChild( 0 ) instanceof TerminalNode
? FrameKind.UNBOUNDED_FOLLOWING
: FrameKind.OFFSET_FOLLOWING;
case HqlParser.ROW -> FrameKind.CURRENT_ROW;
default -> throw new IllegalArgumentException( "Illegal frame kind: " + child );
};
}
@Override
public SqmExpression<?> visitCube(HqlParser.CubeContext ctx) {
return new SqmSummarization<>(
SqmSummarization.Kind.CUBE,
visitExpressions( ctx ),
nodeBuilder()
);
}
@Override
public SqmExpression<?> visitRollup(HqlParser.RollupContext ctx) {
return new SqmSummarization<>(
SqmSummarization.Kind.ROLLUP,
visitExpressions( ctx ),
nodeBuilder()View on GitHub (pinned to fad1729dce)
Solutions
- The window frame bound kind is illegal. Use UNBOUNDED PRECEDING/FOLLOWING, CURRENT ROW, or an offset PRECEDING/FOLLOWING bound.
When it happens
Trigger: The HQL parser produced a node the translator does not expect: Illegal frame kind: <value>
Common situations: Usually an internal grammar edge case in window-frame or expression parsing; can surface with unusual but syntactically accepted HQL.
AI-assisted analysis of hibernate/hibernate-orm@fad1729dce (2026-08-22).
Data as JSON: /api/errors/af7f841a91207b02.
Report an issue: GitHub.