Deleting Apache Iceberg Tables
The DELETE command deletes rows from a table.
DELETE FROM <table_path>.<table_name> [AS alias] [ USING <additional_table_or_query> [, <additional_table_or_query> ] ] [ WHERE where_conditions ]
The path in which the table is located.
The name of the table with data that you want to delete.
If you need to refer to additional tables or subqueries in the WHERE clause to help identify the rows to be removed, then specify those table names in the USING clause. Enclose subqueries in parentheses.
When a WHERE clause contains a JOIN between source tables in the USING clause and the target table, a row in the target table might join with more than one row in the source table. When this condition occurs, the DELETE command fails with an error message.
The filter for specifying which rows of the table to delete.
DELETE FROM target USING src b , (select k, min(v) v from src_new group by k having min(v) < 10) c WHERE target.k = b.k and target.k = c.k;