xxhash
xxhash
pg_xxhash : xxhash functions for PostgreSQL
Overview
| ID | Extension | Package | Version | Category | License | Language |
|---|---|---|---|---|---|---|
| 4430 | xxhash | pg_xxhash | 0.0.1 | UTIL | BSD 2-Clause | C |
| Attribute | Has Binary | Has Library | Need Load | Has DDL | Relocatable | Trusted |
|---|---|---|---|---|---|---|
--s-dtr | No | Yes | No | Yes | yes | yes |
| Relationships | |
|---|---|
| See Also | hashlib shacrypt pgcrypto gzip bzip zstd http pg_net |
Packages
| Type | Repo | Version | PG Major Compatibility | Package Pattern | Dependencies |
|---|---|---|---|---|---|
| EXT | PIGSTY | 0.0.1 | 18 17 16 15 14 | pg_xxhash | - |
| RPM | PIGSTY | 0.0.1 | 18 17 16 15 14 | pg_xxhash_$v | - |
| DEB | PIGSTY | 0.0.1 | 18 17 16 15 14 | postgresql-$v-pg-xxhash | - |
| Linux / PG | PG18 | PG17 | PG16 | PG15 | PG14 |
|---|---|---|---|---|---|
el8.x86_64 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 |
el8.aarch64 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 |
el9.x86_64 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 |
el9.aarch64 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 |
el10.x86_64 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 |
el10.aarch64 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 |
d12.x86_64 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 |
d12.aarch64 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 |
d13.x86_64 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 |
d13.aarch64 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 |
u22.x86_64 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 |
u22.aarch64 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 |
u24.x86_64 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 |
u24.aarch64 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 | PIGSTY 0.0.1 |
Source
pig build pkg pg_xxhash; # build rpm/debInstall
Make sure PGDG and PIGSTY repo available:
pig repo add pgsql -u # add both repo and update cacheInstall this extension with pig:
pig install pg_xxhash; # install via package name, for the active PG version
pig install xxhash; # install by extension name, for the current active PG version
pig install xxhash -v 18; # install for PG 18
pig install xxhash -v 17; # install for PG 17
pig install xxhash -v 16; # install for PG 16
pig install xxhash -v 15; # install for PG 15
pig install xxhash -v 14; # install for PG 14Create this extension with:
CREATE EXTENSION xxhash;Usage
Provides xxHash non-cryptographic hash functions that return hex strings or bytea.
Text Output Functions
SELECT xxh32('https://example.com'); -- 'ba15a4a8'
SELECT xxh64('https://example.com'); -- 'b131752760b48654'
SELECT xxh3_64('https://example.com'); -- '9398cc7c078760e6'
SELECT xxh128('https://example.com'); -- '4879d6aa9d88e9c7a169c008892d4829'Binary Output Functions
SELECT xxh32b('https://example.com'); -- \xba15a4a8
SELECT xxh64b('https://example.com'); -- \xb131752760b48654
SELECT xxh3_64b('https://example.com'); -- \x9398cc7c078760e6
SELECT xxh128b('https://example.com'); -- \x4879d6aa9d88e9c7a169c008892d4829Available Functions
| Function | Bits | Output |
|---|---|---|
xxh32(text) | 32 | hex text |
xxh64(text) | 64 | hex text |
xxh3_64(text) | 64 | hex text |
xxh128(text) | 128 | hex text |
xxh32b(text) | 32 | bytea |
xxh64b(text) | 64 | bytea |
xxh3_64b(text) | 64 | bytea |
xxh128b(text) | 128 | bytea |
Last updated on