Skip to main content

View recycle bin objects

You can run the SHOW RECYCLEBIN statement to view recycle bin objects.

Background information

When you drop a database object:

  • If the recycle bin is enabled, the object is moved to the recycle bin and can be queried.

  • If the recycle bin is disabled, the object is not moved to the recycle bin and cannot be queried.

Procedure

  1. Log in to seekdb as the root user.

    The following example shows how to connect to the database. Please replace the actual environment when connecting to the database.

    mysql -h127.0.0.1 -uroot -P2881
  2. Run the following statement to view recycle bin objects.

    SHOW RECYCLEBIN;
    +--------------------------------+---------------+----------+----------------------------+
    | OBJECT_NAME | ORIGINAL_NAME | TYPE | CREATETIME |
    +--------------------------------+---------------+----------+----------------------------+
    | __recycle_$_1_1765784426825016 | test_db | DATABASE | 2025-12-15 15:40:26.825340 |
    +--------------------------------+---------------+----------+----------------------------+
    1 row in set (0.003 sec)

    The following table describes the related fields in the return result:

    • OBJECT_NAME: the name of the object in the recycle bin.

    • ORIGINAL_NAME: the original name of the object.

    • TYPE: the type of the recycle bin object. Valid values: INDEX, TABLE, and DATABASE.

    • CREATETIME: the time when the object was moved to the recycle bin.

References

For more information about the recycle bin, see the following topics: