ClapDB supports a wide range of data types. The following table lists the data types supported by ClapDB.
Numeric Types
Integer Types
Name | Low Value | High Value | Alias | Description | Equivelent in PostgreSQL |
---|
Bool | false | true | | state of true or false | boolean |
int16 | -32768 | 32767 | smallint or int2 | small-range integer | smallint |
int32 | -2147483648 | 2147483647 | int or int4 | standard integer | integer |
int64 | -9223372036854775808 | 9223372036854775807 | bigint or int8 | large-range integer | bigint |
uint16 | 0 | 65535 | - | 16-bit unsigned integer | not exist |
uint32 | 0 | 4294967295 | - | 32-bit unsigned integer | not exist |
uint64 | 0 | 18446744073709551615 | - | 64-bit unsigned integer | not exist |
Arbitrary Precision Numbers
Decimal
Floating-Point Types
Name | Range | Description | Equivelent in PostgreSQL |
---|
float | 6 decimal digits precision | single-precision floating point number | real |
double | 15 decimal digits precision | double-precision floating point number | double precision |
Text Types
Name | Description | alias | Length Limit | Equivelent in PostgreSQL |
---|
enum | short and low cardinality string | | less than 4MB | not exist |
text | any string | | less than 4MB | text |
Date/Time Types
Name | Description | Low Value | High Value | Resolution | Equivelent in PostgreSQL |
---|
date | date (no time of day) | 9999-01-01 BC | 9999-12-31 AD | 1 day | date |
timestamp | both date and time (no time zone) | 9999-01-01 00:00:00 BC | 9999-12-31 23:59:59 AD | 1 microsecond | timestamp |
timestamptz | both date and time, with time zone | 9999-01-01 00:00:00 BC | 9999-12-31 23:59:59 AD | 1 microsecond | timestamptz |
time | time of day (no date), without time zone | 00:00:00 | 23:59:59 | 1 microsecond | time |
interval | time interval | -178000000 years | 178000000 years | 1 microsecond | interval |
Semi-Structure Types
Name | Length Limit | Description | Equivelent in PostgreSQL |
---|
jsonb | less than 4MB | RFC 8259 | jsonb |
Network Types
ipv4