cgivre commented on code in PR #2794:
URL: https://github.com/apache/drill/pull/2794#discussion_r1168776897


##########
exec/java-exec/src/main/java/org/apache/drill/exec/planner/sql/conversion/DrillRexBuilder.java:
##########
@@ -65,9 +65,9 @@ public RexNode ensureType(
    * @return Call to CAST operator
    */
   @Override
-  public RexNode makeCast(RelDataType type, RexNode exp, boolean 
matchNullability) {
+  public RexNode makeCast(RelDataType type, RexNode exp, boolean 
matchNullability, boolean safe) {

Review Comment:
   This really highlights an issue with Calcite.  They really could have added 
an additional function something like below and nothing would have broken...
   
   
   ```
   makeCast(RelDataType type, RexNode exp, boolean matchNullability) {
      return makeCast(type, exp, matchNullability, false);
   }
   ```



##########
exec/java-exec/src/main/codegen/templates/Parser.jj:
##########
@@ -15,9 +15,11 @@
  * limitations under the License.
  */
 
-// TODO: Delete this file to reinstate its extraction from calcite-core.jar
-// once CALCITE-5579 is resolved and the incompatible grammar changes 
introduced
-// by CALCITE-5469 have been backed out. Also see: exec/java-exec/pom.xml.

Review Comment:
   Do we want to leave the original info here just so that we know which 
Calcite PRs we're waiting for?



##########
exec/java-exec/src/main/codegen/templates/Parser.jj:
##########
@@ -7727,6 +7764,8 @@ SqlPostfixOperator PostfixRowOperator() :
 |   < DATETIME_INTERVAL_CODE: "DATETIME_INTERVAL_CODE" >
 |   < DATETIME_INTERVAL_PRECISION: "DATETIME_INTERVAL_PRECISION" >
 |   < DAY: "DAY" >
+|   < DAYOFWEEK: "DAYOFWEEK" >
+|   < DAYOFYEAR: "DAYOFYEAR" >

Review Comment:
   Should we add a unit test for these synonyms?



-- 
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: dev-unsubscr...@drill.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to