Varbit and toast

Started by Olga Lytvynova-Bogdanovaover 8 years ago2 messagesgeneral
Jump to latest
#1Olga Lytvynova-Bogdanova
olytvynovabogdanova@gmail.com

Hello,
I would like to ask whether is VARBIT a TOAST-able type and table should
support row insertion with VARBIT values more than 8 KB in size thus?
Regards
Olha

#2Pavel Stehule
pavel.stehule@gmail.com
In reply to: Olga Lytvynova-Bogdanova (#1)
Re: Varbit and toast

Hi

2017-12-13 16:22 GMT+01:00 Olga Lytvynova-Bogdanova <
olytvynovabogdanova@gmail.com>:

Hello,
I would like to ask whether is VARBIT a TOAST-able type and table should
support row insertion with VARBIT values more than 8 KB in size thus?
Regards
Olha

postgres=# select * from pg_type where typname = 'varbit';
+-[ RECORD 1 ]---+-----------------+
| typname | varbit |
| typnamespace | 11 |
| typowner | 10 |
| typlen | -1 |
| typbyval | f |
| typtype | b |
| typcategory | V |
| typispreferred | t |
| typisdefined | t |
| typdelim | , |
| typrelid | 0 |
| typelem | 0 |
| typarray | 1563 |
| typinput | varbit_in |
| typoutput | varbit_out |
| typreceive | varbit_recv |
| typsend | varbit_send |
| typmodin | varbittypmodin |
| typmodout | varbittypmodout |
| typanalyze | - |
| typalign | i |
| typstorage | x |
| typnotnull | f |
| typbasetype | 0 |
| typtypmod | -1 |
| typndims | 0 |
| typcollation | 0 |
| typdefaultbin | |
| typdefault | |
| typacl | |
+----------------+-----------------+

look https://www.postgresql.org/docs/current/static/catalog-pg-type.html
typstorage = 'x'

x: Value can be stored compressed inline or stored in “secondary” storage.

Regards

Pavel