You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues-all@impala.apache.org by "Zoltán Borók-Nagy (Jira)" <ji...@apache.org> on 2023/05/11 14:34:00 UTC

[jira] [Assigned] (IMPALA-12136) Rewrite DELETE statements to TRUNCATE if possible

     [ https://issues.apache.org/jira/browse/IMPALA-12136?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Zoltán Borók-Nagy reassigned IMPALA-12136:
------------------------------------------

    Assignee: Zoltán Borók-Nagy

> Rewrite DELETE statements to TRUNCATE if possible
> -------------------------------------------------
>
>                 Key: IMPALA-12136
>                 URL: https://issues.apache.org/jira/browse/IMPALA-12136
>             Project: IMPALA
>          Issue Type: Bug
>            Reporter: Zoltán Borók-Nagy
>            Assignee: Zoltán Borók-Nagy
>            Priority: Major
>              Labels: impala-iceberg
>
> If the user issues DELETE FROM t; to remove all rows from a table, we should rewrite it to TRUNCATE TABLE t; as it is much more efficient in some cases.
> E.g., for Iceberg tables DELETE FROM t; would create delete files that contain all existing rows. Then subsequent readers would have to read all data files and delete files just to return an empty result set. Wherease TRUNCATE TABLE t; just creates a new empty table snapshot.
> We'll need to investigate if it makes sense for Kudu tables as well.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-all-unsubscribe@impala.apache.org
For additional commands, e-mail: issues-all-help@impala.apache.org