Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-32516

path option is treated differently for 'format("parquet").load(path)' vs. 'parquet(path)'

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 2.4.6, 3.0.0
    • 3.1.0
    • SQL
    • None

    Description

      When data is read, "path" option is treated differently depending on how dataframe is created:

      scala> Seq(1).toDF.write.mode("overwrite").parquet("/tmp/test")
                                                                                      
      scala> spark.read.option("path", "/tmp/test").format("parquet").load("/tmp/test").show
      +-----+
      |value|
      +-----+
      |    1|
      +-----+
      
      
      scala> spark.read.option("path", "/tmp/test").parquet("/tmp/test").show
      +-----+
      |value|
      +-----+
      |    1|
      |    1|
      +-----+
      

      Attachments

        Activity

          People

            imback82 Terry Kim
            imback82 Terry Kim
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: