Github user yhuai commented on a diff in the pull request:

    https://github.com/apache/spark/pull/8990#discussion_r41225536
  
    --- Diff: 
sql/hive/src/test/scala/org/apache/spark/sql/hive/execution/SQLQuerySuite.scala 
---
    @@ -1248,4 +1248,12 @@ class SQLQuerySuite extends QueryTest with 
SQLTestUtils with TestHiveSingleton {
             """.stripMargin), Row("b", 6.0) :: Row("a", 7.0) :: Nil)
         }
       }
    +
    +  test("SPARK-10337: correctly handle hive views") {
    +    withSQLConf("spark.sql.hive.nonNativeView" -> "true") {
    +      sqlContext.range(1, 10).write.format("json").saveAsTable("jt")
    +      sql("CREATE VIEW testView AS SELECT id FROM jt")
    +      checkAnswer(sql("SELECT * FROM testView ORDER BY id"), (1 to 
9).map(i => Row(i)))
    +    }
    +  }
    --- End diff --
    
    Also, do we need to design more cases to test when this flag is true?


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