cloud-fan commented on a change in pull request #34839:
URL: https://github.com/apache/spark/pull/34839#discussion_r766484032



##########
File path: 
sql/core/src/test/scala/org/apache/spark/sql/execution/SQLViewTestSuite.scala
##########
@@ -393,6 +393,18 @@ abstract class SQLViewTestSuite extends QueryTest with 
SQLTestUtils {
       assert(e2.message.contains("Cannot time travel views"))
     }
   }
+
+  test("SPARK-37569: view should report correct nullability information for 
nested fields") {
+    withView("v") {
+      val sql = "SELECT id, named_struct('a', id) AS nested FROM RANGE(10)"
+      val df = spark.sql(sql)
+
+      spark.sql(s"CREATE VIEW v AS $sql")

Review comment:
       We should call the `createView` method to create view, otherwise we just 
test the permanent view 3 times...




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



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

Reply via email to