pyspark.sql.Catalog.dropGlobalTempView¶
-
Catalog.
dropGlobalTempView
(viewName: str) → None¶ Drops the global temporary view with the given view name in the catalog. If the view has been cached before, then it will also be uncached. Returns true if this view is dropped successfully, false otherwise.
Examples
>>> spark.createDataFrame([(1, 1)]).createGlobalTempView("my_table") >>> spark.table("global_temp.my_table").collect() [Row(_1=1, _2=1)] >>> spark.catalog.dropGlobalTempView("my_table") True >>> spark.table("global_temp.my_table") Traceback (most recent call last): ... AnalysisException: ...