Dragonliu2018 opened a new issue, #35748: URL: https://github.com/apache/doris/issues/35748
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/doris/issues?q=is%3Aissue) and found no similar issues. ### Description When drop a database which is not in catalog recycle bin, the current code simply reports errors without removing all tables and partitions in catalog recycle bin with same DbId. Such as: ```sql mysql> show catalog recycle bin; +-----------+------+-------+---------+-------------+---------------------+----------+----------------+ | Type | Name | DbId | TableId | PartitionId | DropTime | DataSize | RemoteDataSize | +-----------+------+-------+---------+-------------+---------------------+----------+----------------+ | Partition | p30 | 12056 | 12258 | 12257 | 2024-05-31 22:36:45 | 0.000 | 0.000 | +-----------+------+-------+---------+-------------+---------------------+----------+----------------+ 1 row in set (0.01 sec) mysql> drop catalog recycle bin where 'dbid' = 12056; ERROR 1105 (HY000): errCode = 2, detailMessage = errCode = 2, detailMessage = Unknown database id '12056' ``` Would it be better if remove them? ### Solution refer to: #31893 ### Are you willing to submit PR? - [X] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org