You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2019/12/02 22:51:57 UTC

[GitHub] [spark] maropu commented on a change in pull request #26716: [SPARK-30083][SQL] visitArithmeticUnary should wrap PLUS case with UnaryPositive for type checking

maropu commented on a change in pull request #26716: [SPARK-30083][SQL] visitArithmeticUnary should wrap PLUS case with UnaryPositive for type checking
URL: https://github.com/apache/spark/pull/26716#discussion_r352902281
 
 

 ##########
 File path: docs/sql-migration-guide.md
 ##########
 @@ -254,6 +254,8 @@ license: |
         </tr>
     </table>
 
+    - Since Spark 3.0, the unary arithmetic operator plus(`+`) only accept string, numeric and interval type values as inputs. Besides, `+` with a integral string representation will be coerced to double value, e.g. `+'1'` results `1.0`. In Spark version 2.4 and earlier,  there is no type checking for it, thus, all type values with a `+` prefix is valid, e.g. `+ array(1, 2)` is valid and results `[1, 2]`. Besides, there is no implicit type coercion for `+` with string, e.g. `+'1'` results `1`.
 
 Review comment:
   nit: accept -> accepts

----------------------------------------------------------------
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

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org