xuanyuanking commented on a change in pull request #30148:
URL: https://github.com/apache/spark/pull/30148#discussion_r519544344



##########
File path: 
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/Analyzer.scala
##########
@@ -878,6 +878,14 @@ class Analyzer(
         case _ => None
       }
 
+      val isStreamingTmpView = tmpView.nonEmpty && tmpView.get.isStreaming

Review comment:
       @cloud-fan @HeartSaVioR Bring back the 
discussion(https://github.com/apache/spark/pull/30148#discussion_r517785184) 
here:
   After taking a further look, moving the checking logic in the Analyser rule 
will break both SQL and DataSet API on the reading streaming temp view.
   I can only block the streaming temp view reading in the DataSet side, but it 
breaks the consistency between both APIs, as we don't have streaming keywords 
in SQL to distinguish the table/view is whether streaming or not. So I just 
unify the code path and add comments to emphasize the current behavior of 
`spark.table` and `spark.read.table`.




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



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

Reply via email to