作者
digoal
日期
2020-03-24
标签
PostgreSQL , 压缩 , zstd
背景
https://github.com/grahamedgecombe/pgzstd
Postgres module for Zstandard compression/decompression with preset dictionary support
```
gpe=# CREATE EXTENSION zstd;
CREATE EXTENSION
gpe=# SELECT zstd_compress('hello hello hello hello', 'hello hello', 3);
zstd_compress
\x28b52ffd2017450000000200291c6c1420
(1 row)
gpe=# SELECT convert_from(zstd_decompress('\x28b52ffd2017450000000200291c6c1420', 'hello hello'), 'utf-8');
convert_from
hello hello hello hello
(1 row)
gpe=# SELECT zstd_length('\x28b52ffd2017450000000200291c6c1420');
zstd_length
23
复制
(1 row)
gpe=#
```
PostgreSQL 许愿链接
您的愿望将传达给PG kernel hacker、数据库厂商等, 帮助提高数据库产品质量和功能, 说不定下一个PG版本就有您提出的功能点. 针对非常好的提议,奖励限量版PG文化衫、纪念品、贴纸、PG热门书籍等,奖品丰富,快来许愿。开不开森.