Note
For V4.4.1, this parameter is available starting with V4.4.1.
Description
The enable_database_sharding_none parameter specifies whether to enable automatic aggregation (automatic table group binding) for user tables when a database is created.
Applicability
This parameter applies only to OceanBase Database in MySQL-compatible mode.
Privilege requirements
Query the parameter
The
systenant and all user tenants can query this parameter by using theSHOW PARAMETERSstatement or theGV$OB_PARAMETERSview.Modify the parameter
The
systenant and user tenants can modify this parameter.
Attributes
| Attribute | Description |
|---|---|
| Type | Boolean. |
| Default value | False. |
| Value range |
|
| Modifiable | Yes. You can use the ALTER SYSTEM SET statement to modify the parameter. |
| Effective upon OBServer node restart | No. The setting takes effect immediately. |
Considerations
Set the
enable_database_sharding_noneparameter toTrue:- When a new database is created, it is automatically bound to a table group with
SHARDING = 'NONE'. All user tables in this database are bound to the same log stream. - This does not affect existing databases.
- When a new database is created, it is automatically bound to a table group with
Set the
enable_database_sharding_noneparameter toFalse:- This does not affect existing databases.
Examples
Set the enable_database_sharding_none parameter to True to enable automatic aggregation for user tables when a database is created.
obclient> ALTER SYSTEM SET enable_database_sharding_none = True;