mihaibudiu commented on code in PR #4388:
URL: https://github.com/apache/calcite/pull/4388#discussion_r2094584188
##########
core/src/main/java/org/apache/calcite/sql/validate/SqlValidatorImpl.java:
##########
@@ -5874,6 +5874,11 @@ private void validateSnapshot(
throw newValidationError(period,
Static.RESOURCE.illegalExpressionForTemporal(dataType.getSqlTypeName().getName()));
}
+ if (ns instanceof IdentifierNamespace && ns.resolve() instanceof
WithItemNamespace) {
+ // If the snapshot is used over a CTE, then we don't have a concrete
underlying
+ // table to operate on. This will be rechecked later in the planner
rules.
Review Comment:
there is no guarantee that any planner rules will be executed after
validation.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]