> ## Documentation Index
> Fetch the complete documentation index at: /documents/llms.txt
> Use this file to discover all available pages before exploring further.

# SHOW DELETE

> SHOW DELETE queries historical DELETE operations that were successfully performed on Duplicate Key, Unique Key, and Aggregate tables in a specified database.

SHOW DELETE queries historical DELETE operations that were successfully performed on Duplicate Key, Unique Key, and Aggregate tables in a specified database. For more information about data deletion, see [DELETE](/documents/4.2/sql-reference/sql-statements/table_bucket_part_index/DELETE.md).

Note that this command cannot be used to query DELETE operations that were performed on Primary Key tables.

## Syntax

```sql theme={null}
SHOW DELETE [FROM <db_name>]
```

`db_name`: the database name, optional. If this parameter is not specified, the current database is used by default.

Return fields:

* `TableName`: the table from which data is deleted.
* `PartitionName`: the partition from which data is deleted. If the table is a non-partitioned table, `*` is displayed.
* `CreateTime`: the time when the DELETE task was created.
* `DeleteCondition`: the specified DELETE condition.
* `State`: the status of the DELETE task.

## Examples

Show all historical DELETE operations of `database`.

```sql theme={null}
SHOW DELETE FROM database;

+------------+---------------+---------------------+-----------------+----------+
| TableName  | PartitionName | CreateTime          | DeleteCondition | State    |
+------------+---------------+---------------------+-----------------+----------+
| mail_merge | *             | 2023-03-14 10:39:03 | name EQ "Peter" | FINISHED |
+------------+---------------+---------------------+-----------------+----------+
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.