GitHub user dongjoon-hyun opened a pull request:

    https://github.com/apache/spark/pull/15376

    [SPARK-17796][SQL] Support wildcard character in filename for LOAD DATA 
LOCAL INPATH

    ## What changes were proposed in this pull request?
    
    Currently, Spark 2.0 raises a `input path does not exist` AnalysisException 
if the file name contains '*'. It is misleading since it occurs when there 
exists some matched files. It was a supported feature in Spark 1.6.2. This PR 
aims to support wildcard characters in filename for LOAD DATA LOCAL INPATH like 
Spark 1.6.2.
    
    **Spark 2.0**
    ```scala
    scala> sql("CREATE TABLE t(a string)")
    res0: org.apache.spark.sql.DataFrame = []
    
    scala> sql("LOAD DATA LOCAL INPATH '/tmp/x*' INTO TABLE t")
    org.apache.spark.sql.AnalysisException: LOAD DATA input path does not 
exist: /tmp/x*;
    ```
    
    ## How was this patch tested?
    
    Pass the Jenkins test with a new test case.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/dongjoon-hyun/spark SPARK-17796

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/spark/pull/15376.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #15376
    
----
commit dfdfc463140d73d2abefcfc4e728d31ccac5cf40
Author: Dongjoon Hyun <dongj...@apache.org>
Date:   2016-10-06T07:13:32Z

    [SPARK-17796][SQL] Support wildcard character in filename for LOAD DATA 
LOCAL INPATH

----


---
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 infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

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

Reply via email to