Github user adrian-wang commented on the pull request:

    https://github.com/apache/spark/pull/4945#issuecomment-77998513
  
    @liancheng That's reasonable, not every string could be converted into 
numeric types.
    Hive specified about this as
    /**
     * GenericUDFIn
     *
     * Example usage:
     * SELECT key FROM src WHERE key IN ("238", "1");
     *
     * From MySQL page on IN(): To comply with the SQL standard, IN returns NULL
     * not only if the expression on the left hand side is NULL, but also if no
     * match is found in the list and one of the expressions in the list is 
NULL.
     *
     * Also noteworthy: type conversion behavior is different from MySQL. With
     * expr IN expr1, expr2... in MySQL, exprN will each be converted into the 
same
     * type as expr. In the Hive implementation, all expr(N) will be converted 
into
     * a common type for conversion consistency with other UDF's, and to prevent
     * conversions from a big type to a small type (e.g. int to tinyint)
     */


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to