Note
This variable is available starting with V2.1.
Description
recyclebin specifies whether to enable the recycle bin.
Privilege requirements
Query variables
Global level
systenant and all user tenants can execute theSHOW VARIABLESstatement or query theSYS.TENANT_VIRTUAL_GLOBAL_VARIABLEview (Oracle mode) or theinformation_schema.GLOBAL_VARIABLESview (MySQL mode) to view the value of global system variables.Session level
systenant and all user tenants can execute theSHOW VARIABLESstatement or query theSYS.TENANT_VIRTUAL_SESSION_VARIABLEview (Oracle mode) or theinformation_schema.SESSION_VARIABLESview (MySQL mode) to view the value of session system variables.
Modify variables
Global level
systenant can directly modify the value of global system variables.MySQL user tenants must have the
SUPERorALTER SYSTEMprivilege to modify the value of global system variables.Oracle user tenants must have the
ALTER SYSTEMprivilege to modify the value of global system variables.
Session level
systenant and all user tenants can directly modify the value of session system variables.
Attributes
| Attribute | Description |
|---|---|
| Type | Bool |
| Default value | OFF |
| Value range |
|
| Scope |
|
| Modifiable | Yes. You can execute the SET statement to modify the value. |
Usage notes
If you enable the recycle bin (recyclebin is set to ON), the deleted tables and their dependent objects are stored in the recycle bin. If you disable the recycle bin (recyclebin is set to OFF), the deleted tables and their dependent objects are directly deleted without being stored in the recycle bin.
Examples
Enable the recycle bin.
Session level
obclient> SET recyclebin = ON;Global level
obclient> SET GLOBAL recyclebin = ON;
References
For more information about recycle bin operations, see the following topics: