Details
-
New Feature
-
Status: Open
-
Major
-
Resolution: Unresolved
-
3.1.0
-
None
-
None
Description
Many databases and data warehouse SQL engines support temporary tables. A temporary table, as its named implied, is a short-lived table that its life will be only for current session.
In Spark, there is no temporary table. the DDL “CREATE TEMPORARY TABLE AS SELECT” will create a temporary view. A temporary view is totally different with a temporary table.
A temporary view is just a VIEW. It doesn’t materialize data in storage. So it has below shortage:
- View will not give improved performance. Materialize intermediate data in temporary tables for a complex query will accurate queries, especially in an ETL pipeline.
- View which calls other views can cause severe performance issues. Even, executing a very complex view may fail in Spark.
- Temporary view has no database namespace. In some complex ETL pipelines or data warehouse applications, without database prefix is not convenient. It needs some tables which only used in current session.
More details are described in Design Docs
Attachments
Issue Links
- relates to
-
SPARK-33459 Commonly used Teradata extension syntax
- Open
1.
|
Supporting create temporary table | In Progress | Unassigned | |
2.
|
Supporting analyze temporary table | Open | Unassigned | |
3.
|
Supporting create temporary table LIKE | Open | Unassigned |