You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@calcite.apache.org by GitBox <gi...@apache.org> on 2019/10/21 02:45:45 UTC

[GitHub] [calcite] danny0405 commented on a change in pull request #1414: [CALCITE-3293] Add strcmp function

danny0405 commented on a change in pull request #1414: [CALCITE-3293] Add strcmp function
URL: https://github.com/apache/calcite/pull/1414#discussion_r336821983
 
 

 ##########
 File path: core/src/main/java/org/apache/calcite/runtime/SqlFunctions.java
 ##########
 @@ -396,6 +396,11 @@ public static ByteString concat(ByteString s0, ByteString s1) {
     return s0.concat(s1);
   }
 
+  /** SQL {@code string compare string} operator. */
+  public static Integer strcmp(String s0, String s1) {
+    return s0.compareTo(s1);
+  }
 
 Review comment:
   The doc is confusing, what is `{@code string compare string} operator` ?

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services