maropu commented on a change in pull request #26361: [SPARK-29630][SQL] 
Disallow creating a permanent view that references a temporary view in an 
expression
URL: https://github.com/apache/spark/pull/26361#discussion_r341828624
 
 

 ##########
 File path: 
sql/core/src/test/resources/sql-tests/results/postgreSQL/create_view.sql.out
 ##########
 @@ -887,35 +890,17 @@ AND NOT EXISTS (SELECT g FROM tbl4 LEFT JOIN tmptbl ON 
tbl4.h = tmptbl.j)
 -- !query 78 schema
 struct<>
 -- !query 78 output
-
+org.apache.spark.sql.AnalysisException
+Not allowed to create a permanent view `mytempview` by referencing a temporary 
view `tmptbl`;
 
 Review comment:
   Ur, I see. This test should be passed (see: 
https://github.com/postgres/postgres/blob/43753c2cfbdd9870e68671abcc9dd377881071b0/src/test/regress/expected/create_view.out#L229)
 because views can depend on temp tables in pgSQL. So, can you replace `CREATE 
TEMP VIEW tmptbl` with `CREATE TABLE tmptbl`:
   
https://github.com/apache/spark/blob/be022d9aeeb6b39f7b51427d848600e15a100c30/sql/core/src/test/resources/sql-tests/inputs/postgreSQL/create_view.sql#L252

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

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

Reply via email to