You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@calcite.apache.org by "liuyongvs (via GitHub)" <gi...@apache.org> on 2023/06/11 04:03:24 UTC

[GitHub] [calcite] liuyongvs commented on a diff in pull request #3260: [CALCITE-5751] Add ARRAY_APPEND, ARRAY_POSITION, ARRAY_REMOVE, ARRAY_…

liuyongvs commented on code in PR #3260:
URL: https://github.com/apache/calcite/pull/3260#discussion_r1225698063


##########
core/src/main/java/org/apache/calcite/runtime/SqlFunctions.java:
##########
@@ -3931,6 +3939,34 @@ public static List distinct(List list) {
     return min;
   }
 

Review Comment:
   comments:
   it can not use 
   
   ```
   list.add
   return list;
   ```
   because it will throw exception
   java.lang.UnsupportedOperationException
   	at java.util.AbstractList.add(AbstractList.java:148)
   	at java.util.AbstractList.add(AbstractList.java:108)
   	at org.apache.calcite.runtime.SqlFunctions.arrayAppend(SqlFunctions.java:3899)



-- 
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: commits-unsubscribe@calcite.apache.org

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