This topic provides information on managing the recycle bin.
Background information
The recycle bin temporarily stores deleted database objects. ODC allows you to search for and recover the deleted database objects.
Technically, the recycle bin is a data dictionary table that stores the information about deleted database objects. Deletion here refers to the DROP operation. Data that is deleted by the DELETE operation will not be moved to the recycle bin. Therefore, an object deleted by the DROP operation is not permanently deleted and still occupies storage space. You can use the PURGE operation or empty the recycle bin in ODC to release the space.
Query the recycle bin
Assume that you want to query the database objects under the data source mysql420 in the SQL development window.
In the left-side navigation pane, choose
O&M Management >Recycle Bin .
Select the data source
mysql420and clickOK .
On the
Recycle Bin page, you can query all database objects deleted from the data sourcemysql420.
Parameter Description Original Name The name of the deleted object specified by its creator. You can click Original Name to sort the objects by original name in ascending or descending order. Object Name The name that ODC gives to the object. Unlike the original name, the object name is never repeated and can uniquely identify an object. Object Type The type of the deleted object. Recycled At The timestamp when the object was deleted. The timestamps help you track deleted objects with ease.
Edit the recycle bin
Assume that you want to query the ccc table in the data source mysql420 in the SQL development window.
| Parameter | Example |
|---|---|
| Data Source | mysql420 |
| Database Table | ccc |
In the recycle bin list, select the
ccctable and clickRestore .
On the
Restore Database Object page, you can rename the object and clickRestore .
In addition, the navigation bar on the recycle bin page provides buttons with the following features.
Feature Description Delete Click
to purge the selected objects from the recycle bin and release the storage space.Restore Click
to recover the selected objects from the recycle bin to its original location.Clear Click
to clear the recycle bin so that all the deleted objects in the recycle bin are purged and the storage space is released.Search Enter the name of a deleted object in the search field to search for it. Settings Click
to specify whether to enable the recycle bin and the Truncate Table feature.
- If the recycle bin is enabled, the structure of deleted objects will be moved to the recycle bin.
- If the Truncate Table feature is enabled, the data of deleted objects will be retained.
Refresh Click
to refresh the list of deleted objects in the recycle bin.Select All Click the
icon to select or deselect all objects. 
In the
SQL Confirmation dialog box, confirm the SQL statement and clickExecute .