Note
This parameter is available starting with V1.4.
Description
default_compress_func specifies the default compression algorithm for table data. You can also specify a different compression algorithm when you create a table.
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
Only the
systenant can modify this parameter. User tenants cannot modify this parameter.
Attributes
| Attribute | Description |
|---|---|
| Type | String |
| Default value | zstd_1.3.8 |
| 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
The compression algorithms of different minor versions of zlib may produce inconsistent compression results for the same data. To avoid issues with data recovery during OceanBase Database upgrades, OceanBase Database no longer supports the zlib_1.0 compression algorithm starting with V4.2.2.
Examples
Set the default compression algorithm for table data to lz4_1.0.
obclient> ALTER SYSTEM SET default_compress_func = 'lz4_1.0';