hashtypes
sha1, md5 and other data types for PostgreSQL
hashtypes : sha1, md5 and other data types for PostgreSQL
Overview
| ID | Extension | Package | Version | Category | License | Language |
|---|---|---|---|---|---|---|
| 3750 | hashtypes | hashtypes | 0.1.5 |
TYPE | PostgreSQL | C |
| Attribute | Has Binary | Has Library | Need Load | Has DDL | Relocatable | Trusted |
|---|---|---|---|---|---|---|
| --s-d-- | No | Yes | No | Yes | no | no |
Packages
| Type | Repo | Version | PG Major Compatibility | Package Pattern | Dependencies |
|---|---|---|---|---|---|
| EXT | PIGSTY | 0.1.5 |
18 17 16 15 14 | hashtypes |
- |
| RPM | PIGSTY | 0.1.5 |
18 17 16 15 14 | hashtypes_$v |
- |
| DEB | PIGSTY | 0.1.5 |
18 17 16 15 14 | postgresql-$v-hashtypes |
- |
| Linux / PG | PG18 | PG17 | PG16 | PG15 | PG14 |
|---|---|---|---|---|---|
| el8.x86_64 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 |
| el8.aarch64 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 |
| el9.x86_64 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 |
| el9.aarch64 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 |
| el10.x86_64 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 |
| el10.aarch64 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 |
| d12.x86_64 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 |
| d12.aarch64 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 |
| d13.x86_64 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 |
| d13.aarch64 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 |
| u22.x86_64 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 |
| u22.aarch64 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 |
| u24.x86_64 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 |
| u24.aarch64 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 |
| u26.x86_64 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 |
| u26.aarch64 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 | PIGSTY 0.1.5 |
Source
github.com/adjust/hashtypes/
hashtypes-0.1.5.tar.gz
Install
Make sure PGDG and PIGSTY repo available:
Install this extension with pig:
Create this extension with:
Usage
The hashtypes extension provides native data types for storing hash values and checksums in their binary representation, saving storage compared to text.
Data Types
| Type | Storage | Description |
|---|---|---|
sha1 |
20 bytes | SHA-1 hash (160-bit) |
sha224 |
28 bytes | SHA-224 hash (224-bit) |
sha256 |
32 bytes | SHA-256 hash (256-bit) |
sha384 |
48 bytes | SHA-384 hash (384-bit) |
sha512 |
64 bytes | SHA-512 hash (512-bit) |
crc32 |
4 bytes | CRC-32 checksum |
Usage
Operators
All types support comparison operators: =, <>, <, >, <=, >=.
Index Support
Btree and hash index operator classes are provided for all types.
Casts
All types support bidirectional casts to/from text and bytea.