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

Add test cases for CREATE EXTERNAL TABLE with subdirectories

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 2.3.2
    • 3.0.0
    • SQL, Tests
    • None

    Description

      Add a test case based on the following example. The behavior was changed in 2.3 release. We also need to upgrade the migration guide.

      val someDF1 = Seq(
        (1, 1, "blah"),
        (1, 2, "blahblah")
      ).toDF("folder", "number", "word").repartition(1)
      
      someDF1.write.orc("/tmp/orctab1/dir1/")
      someDF1.write.orc("/mnt/orctab1/dir2/")
      
      create external table tab1(folder int,number int,word string) STORED AS ORC LOCATION '/tmp/orctab1/");
      select * from tab1;
      
      create external table tab2(folder int,number int,word string) STORED AS ORC LOCATION '/tmp/orctab1/*");
      select * from tab2;
      

      Attachments

        Activity

          People

            kevinyu98 kevin yu
            smilegator Xiao Li
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: