{"kind": "type", "slug": "aclitem", "name": "aclitem", "major": "18", "snapshot": {"casts": [], "facts": [{"label": "Catalog name", "value": "pg_catalog.aclitem"}, {"label": "Type OID", "value": "1033"}, {"label": "Type kind", "value": "Base type"}, {"label": "Declared length", "value": "16 bytes"}, {"label": "Storage strategy", "value": "plain"}, {"label": "Input function", "value": "aclitemin"}, {"label": "Output function", "value": "aclitemout"}, {"label": "Documented declaration", "value": "typacl aclitem[] Access privileges; see Section 5.8 for details"}], "ranges": [], "aliases": [], "catalog": {"oid": "1033", "descr": "access control list", "typacl": "_null_", "typlen": "16", "typelem": "0", "typname": "aclitem", "typsend": "-", "typtype": "b", "typalign": "d", "typarray": "0", "typbyval": "f", "typdelim": "','", "typinput": "aclitemin", "typmodin": "-", "typndims": "0", "typowner": "POSTGRES", "typrelid": "0", "typmodout": "-", "typoutput": "aclitemout", "typtypmod": "-1", "typanalyze": "-", "typdefault": "_null_", "typnotnull": "f", "typreceive": "-", "typstorage": "p", "typbasetype": "0", "typcategory": "U", "typcollation": "0", "typisdefined": "t", "typnamespace": "pg_catalog", "typsubscript": "-", "typdefaultbin": "_null_", "array_type_oid": "1034", "typispreferred": "f", "array_type_name": "_aclitem"}, "related": [{"url": "/wiki/catalog/pg_type/?v=18", "label": "pg_type catalog"}, {"url": "/wiki/catalog/pg_cast/?v=18", "label": "pg_cast catalog"}, {"url": "/wiki/catalog/pg_operator/?v=18", "label": "pg_operator catalog"}, {"url": "/wiki/catalog/pg_opclass/?v=18", "label": "pg_opclass catalog"}, {"url": "/wiki/type/arrays/?v=18", "label": "Arrays"}, {"url": "/wiki/indexam/hash/?v=18", "label": "hash index access method"}], "release": {"ref": "https://ftp.postgresql.org/pub/source/v18.6/postgresql-18.6.tar.bz2", "label": "18.6", "major": "18", "channel": "stable", "revision": "555610c24d53e4316da5b7d3fc25c279d96856d5e0e23ee308c328c5fa881d9f", "source_files": {"doc/src/sgml/datatype.sgml": "86328daa77e20d81d222376ec0306d9841a17104e436c08d138eb763aefb3700", "src/include/catalog/pg_am.h": "3426799df799f32163fcc0765f43dbdb5e88e626acf31284fef9fc6014b69d8e", "src/include/catalog/pg_am.dat": "b3cb86b102a42fb0024cbd99779c9897afb40d12a71f5cc5a0e5aee7ff2f9969", "src/include/catalog/pg_cast.h": "de585c7df687d698e7d1d100dce8a794ac9da52414ea48169191019178c8f053", "src/include/catalog/pg_proc.h": "f7d59f07c5b95e2f3c7141762a0f576e8a3af7581ba54c27537f4d500472bea5", "src/include/catalog/pg_type.h": "8fb198749fd82b6c1818a3c18455f226f66116fcfeb3d4959c65ce3fda22802e", "src/include/catalog/pg_range.h": "45546d952b5181f989bd9234721897fc2b37005c8e49ce2ddc156f26974c3ca4", "src/include/catalog/pg_cast.dat": "97911281ca2c81917394ccb2ec13367e37c6801fd461d5e1a3d2f28b911b46b2", "src/include/catalog/pg_proc.dat": "1f934ce80d460159dda137714374a35f9896315ea2476709cbb4da13b38ef95a", "src/include/catalog/pg_type.dat": "5f5887b75677cba2d4a1a0cfeb355df5ed91f85d385fac88bd8d7c605b3578f9", "src/include/catalog/pg_opclass.h": "9c218537806c8ef0398302faaca7f91315dfc1198c48706cebffb479b68defaf", "src/include/catalog/pg_range.dat": "5c2271f8e89e9378d1887204e5785060b77405b5f0ff3e6c719250c9c1dcfcc4", "src/include/catalog/pg_operator.h": "621b18cfffe102413d79b746ce7a10f77fc60fdd097bac34c22b31070d3ee3c4", "src/include/catalog/pg_opfamily.h": "e1f5fc8aebd3042df847455bf66bf755f768c2aa8a9b03d22f7ec8563eba59c0", "src/include/catalog/pg_opclass.dat": "4ee7d3619a6aa106e1c0db55de903931c7d11b1c60ba053a022519c55f8ee668", "src/include/catalog/pg_operator.dat": "5d35b9b2ef5f9797cc815263927ef8a12367fedace53e828b4e8b320e2a7f703", "src/include/catalog/pg_opfamily.dat": "3b694879027b858f2ecf1fa1152b7e30c6e15a216ba99c2384291c30e9d52311"}, "manual_sha256": {"arrays.html": "0e1d5c5a7b4a949d4439995f44f74ad4264e050d16eb9ad2a850fbaee04032df", "domains.html": "82d486973ccc35d14276627a67ac76b434452f23f9ed4d8aa3fbb01fdf285fc2", "datatype.html": "e581f67c74e42006289638c8659e9b338adbfd7f068bd8bf2b3be3880fcd2254", "rowtypes.html": "74f99e029c3a9edfd3e18810ba3c8cb66d3aada91eb67b86476560871e6617e9", "rangetypes.html": "e4960abc7ce8e51d794f94f1e57b099d30b7f75dd7f2b23a960eef91f6291c33", "datatype-bit.html": "c49124aad561636c18080b9e09572fde7785a6b9eae86f5a33283f0fd6774c37", "datatype-oid.html": "8b3360302225f08ae72716ce1804596de95b568e5d31f788cb4597427b28cc38", "datatype-xml.html": "061fc2295b7b69be704f0a741b8decd10ad721059f871fb0243c669bb54d7822", "datatype-enum.html": "cab38e53222e30cc94b24de4b33634fd22d7c93f58ebcf35f646c9b8da78fae8", "datatype-json.html": "650162a05b660146b500a205d523374d00aee117a6a6240d30262be51b6e33e5", "datatype-uuid.html": "292b307b3223c6182bdba687e7f69e6dca9038430143ad79d56327f6ed4c3246", "datatype-money.html": "8b29c14b90679683ac5c472b59a0a7e2853f32cc7db43fab417b2697a6879964", "functions-info.html": "78ac80bf81da2e4f4a33f3b850faa86f0f58ec54a083d6c31da557907de0df87", "catalog-pg-type.html": "ea9c9313bab8e92a7da18ebc50c7ff1f908dd80999a7e0ca3bbc82ba626c58d4", "datatype-binary.html": "0c03ec47b76e37888a3da7f5dcfd340128a5d356642a85185cc9ebe17856a904", "datatype-pg-lsn.html": "339172f5107cc7eb7139bec911277647219e92a532cebd0f3da0a5dacf8195af", "datatype-pseudo.html": "c7cf0b8214304bd8702c95f2142671ae5f0d631f83717f9c07d9e1f2579961b4", "datatype-boolean.html": "b633f663e6c8276e7056287640c413aa79dbc15d5353cee0d41653d58d376956", "datatype-numeric.html": "b74619f7ac2f1ca9f85c48073df78c33dd30e464e61baba6008634534edcb500", "sql-createdomain.html": "e94f927196de1b0ea1ce35cd4603c1f6f544439adcc0edf1c4222358e832245b", "datatype-datetime.html": "e366275d8b13845bfa4ef0d68faa093e5f3ecb708a1ec870cbcbf7e425b85699", "datatype-character.html": "c73eebe413ea709a7792e4cfc3cfe9fb68cb496ebe83c3ebaa9d09f8c40d0f73", "datatype-geometric.html": "0eb3053cfe7d6b0a4b5592c5d7af8d97cae527e87f063c5793413bcba5c14cd9", "datatype-net-types.html": "96846e641cc37727ddcd8b8a1aa0dbe33cd9787760a2b4efb0dcb9403d5be63f", "datatype-textsearch.html": "4b15e05be8b49a71b28aea22f2c46d0dbf639a91e7b4fe129a4c737c6daad47c"}, "source_sha256": "555610c24d53e4316da5b7d3fc25c279d96856d5e0e23ee308c328c5fa881d9f"}, "sources": [{"url": "/docs/18/catalog-pg-type.html", "path": "catalog-pg-type.html", "label": "PostgreSQL 18 English manual", "sha256": "ea9c9313bab8e92a7da18ebc50c7ff1f908dd80999a7e0ca3bbc82ba626c58d4"}, {"url": "https://ftp.postgresql.org/pub/source/v18.6/postgresql-18.6.tar.bz2", "label": "Matching PostgreSQL source archive", "sha256": "555610c24d53e4316da5b7d3fc25c279d96856d5e0e23ee308c328c5fa881d9f"}], "coverage": "source inventory; exact declared input types for operator classes", "sections": [], "operators": [{"oid": "966", "descr": "add/update ACL item", "oprcom": "0", "oprcode": "aclinsert", "oprjoin": "-", "oprkind": "b", "oprleft": "_aclitem", "oprname": "+", "oprrest": "-", "oprowner": "POSTGRES", "oprright": "aclitem", "oprnegate": "0", "oprresult": "_aclitem", "oprcanhash": "f", "oprcanmerge": "f", "oprnamespace": "pg_catalog"}, {"oid": "967", "descr": "remove ACL item", "oprcom": "0", "oprcode": "aclremove", "oprjoin": "-", "oprkind": "b", "oprleft": "_aclitem", "oprname": "-", "oprrest": "-", "oprowner": "POSTGRES", "oprright": "aclitem", "oprnegate": "0", "oprresult": "_aclitem", "oprcanhash": "f", "oprcanmerge": "f", "oprnamespace": "pg_catalog"}, {"oid": "968", "descr": "contains", "oprcom": "0", "oprcode": "aclcontains", "oprjoin": "-", "oprkind": "b", "oprleft": "_aclitem", "oprname": "@>", "oprrest": "-", "oprowner": "POSTGRES", "oprright": "aclitem", "oprnegate": "0", "oprresult": "bool", "oprcanhash": "f", "oprcanmerge": "f", "oprnamespace": "pg_catalog"}, {"oid": "974", "descr": "equal", "oprcom": "=(aclitem,aclitem)", "oprcode": "aclitemeq", "oprjoin": "eqjoinsel", "oprkind": "b", "oprleft": "aclitem", "oprname": "=", "oprrest": "eqsel", "oprowner": "POSTGRES", "oprright": "aclitem", "oprnegate": "0", "oprresult": "bool", "oprcanhash": "t", "oprcanmerge": "f", "oprnamespace": "pg_catalog"}], "signature": "aclitem", "description": ["access control list"], "manual_html": "<div class=\"sect1\" id=\"CATALOG-PG-TYPE\">\n<div class=\"titlepage\">\n<div>\n<div>\n<h2 class=\"title\">52.64. <code class=\"structname\">pg_type</code> </h2>\n</div>\n</div>\n</div>\n<p>The catalog <code class=\"structname\">pg_type</code> stores information about data types. Base types and enum types (scalar types) are created with <a class=\"link\" href=\"/docs/18/sql-createtype.html\" title=\"CREATE TYPE\"><code class=\"command\">CREATE TYPE</code></a>, and domains with <a class=\"link\" href=\"/docs/18/sql-createdomain.html\" title=\"CREATE DOMAIN\"><code class=\"command\">CREATE DOMAIN</code></a>. A composite type is automatically created for each table in the database, to represent the row structure of the table. It is also possible to create composite types with <code class=\"command\">CREATE TYPE AS</code>.</p>\n<div class=\"table\" id=\"id-1.10.4.66.4\">\n<p class=\"title\"><strong>Table 52.64. <code class=\"structname\">pg_type</code> Columns</strong></p>\n<div class=\"table-contents\">\n<table class=\"table\">\n\n\n\n<thead>\n<tr>\n<th class=\"catalog_table_entry\">\n<p class=\"column_definition\">Column Type</p>\n<p>Description</p>\n</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">oid</code> <code class=\"type\">oid</code></p>\n<p>Row identifier</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typname</code> <code class=\"type\">name</code></p>\n<p>Data type name</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typnamespace</code> <code class=\"type\">oid</code> (references <a class=\"link\" href=\"/docs/18/catalog-pg-namespace.html\" title=\"52.32. pg_namespace\"><code class=\"structname\">pg_namespace</code></a>.<code class=\"structfield\">oid</code>)</p>\n<p>The OID of the namespace that contains this type</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typowner</code> <code class=\"type\">oid</code> (references <a class=\"link\" href=\"/docs/18/catalog-pg-authid.html\" title=\"52.8. pg_authid\"><code class=\"structname\">pg_authid</code></a>.<code class=\"structfield\">oid</code>)</p>\n<p>Owner of the type</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typlen</code> <code class=\"type\">int2</code></p>\n<p>For a fixed-size type, <code class=\"structfield\">typlen</code> is the number of bytes in the internal representation of the type. But for a variable-length type, <code class=\"structfield\">typlen</code> is negative. -1 indicates a <span class=\"quote\">“<span class=\"quote\">varlena</span>”</span> type (one that has a length word), -2 indicates a null-terminated C string.</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typbyval</code> <code class=\"type\">bool</code></p>\n<p><code class=\"structfield\">typbyval</code> determines whether internal routines pass a value of this type by value or by reference. <code class=\"structfield\">typbyval</code> had better be false if <code class=\"structfield\">typlen</code> is not 1, 2, or 4 (or 8 on machines where Datum is 8 bytes). Variable-length types are always passed by reference. Note that <code class=\"structfield\">typbyval</code> can be false even if the length would allow pass-by-value.</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typtype</code> <code class=\"type\">char</code></p>\n<p><code class=\"structfield\">typtype</code> is <code class=\"literal\">b</code> for a base type, <code class=\"literal\">c</code> for a composite type (e.g., a table's row type), <code class=\"literal\">d</code> for a domain, <code class=\"literal\">e</code> for an enum type, <code class=\"literal\">p</code> for a pseudo-type, <code class=\"literal\">r</code> for a range type, or <code class=\"literal\">m</code> for a multirange type. See also <code class=\"structfield\">typrelid</code> and <code class=\"structfield\">typbasetype</code>.</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typcategory</code> <code class=\"type\">char</code></p>\n<p><code class=\"structfield\">typcategory</code> is an arbitrary classification of data types that is used by the parser to determine which implicit casts should be <span class=\"quote\">“<span class=\"quote\">preferred</span>”</span>. See <a class=\"xref\" href=\"/docs/18/catalog-pg-type.html#CATALOG-TYPCATEGORY-TABLE\" title=\"Table 52.65. typcategory Codes\">Table 52.65</a>.</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typispreferred</code> <code class=\"type\">bool</code></p>\n<p>True if the type is a preferred cast target within its <code class=\"structfield\">typcategory</code></p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typisdefined</code> <code class=\"type\">bool</code></p>\n<p>True if the type is defined, false if this is a placeholder entry for a not-yet-defined type. When <code class=\"structfield\">typisdefined</code> is false, nothing except the type name, namespace, and OID can be relied on.</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typdelim</code> <code class=\"type\">char</code></p>\n<p>Character that separates two values of this type when parsing array input. Note that the delimiter is associated with the array element data type, not the array data type.</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typrelid</code> <code class=\"type\">oid</code> (references <a class=\"link\" href=\"/docs/18/catalog-pg-class.html\" title=\"52.11. pg_class\"><code class=\"structname\">pg_class</code></a>.<code class=\"structfield\">oid</code>)</p>\n<p>If this is a composite type (see <code class=\"structfield\">typtype</code>), then this column points to the <a class=\"link\" href=\"/docs/18/catalog-pg-class.html\" title=\"52.11. pg_class\"><code class=\"structname\">pg_class</code></a> entry that defines the corresponding table. (For a free-standing composite type, the <a class=\"link\" href=\"/docs/18/catalog-pg-class.html\" title=\"52.11. pg_class\"><code class=\"structname\">pg_class</code></a> entry doesn't really represent a table, but it is needed anyway for the type's <a class=\"link\" href=\"/docs/18/catalog-pg-attribute.html\" title=\"52.7. pg_attribute\"><code class=\"structname\">pg_attribute</code></a> entries to link to.) Zero for non-composite types.</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typsubscript</code> <code class=\"type\">regproc</code> (references <a class=\"link\" href=\"/docs/18/catalog-pg-proc.html\" title=\"52.39. pg_proc\"><code class=\"structname\">pg_proc</code></a>.<code class=\"structfield\">oid</code>)</p>\n<p>Subscripting handler function's OID, or zero if this type doesn't support subscripting. Types that are <span class=\"quote\">“<span class=\"quote\">true</span>”</span> array types have <code class=\"structfield\">typsubscript</code> = <code class=\"function\">array_subscript_handler</code>, but other types may have other handler functions to implement specialized subscripting behavior.</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typelem</code> <code class=\"type\">oid</code> (references <a class=\"link\" href=\"/docs/18/catalog-pg-type.html\" title=\"52.64. pg_type\"><code class=\"structname\">pg_type</code></a>.<code class=\"structfield\">oid</code>)</p>\n<p>If <code class=\"structfield\">typelem</code> is not zero then it identifies another row in <code class=\"structname\">pg_type</code>, defining the type yielded by subscripting. This should be zero if <code class=\"structfield\">typsubscript</code> is zero. However, it can be zero when <code class=\"structfield\">typsubscript</code> isn't zero, if the handler doesn't need <code class=\"structfield\">typelem</code> to determine the subscripting result type. Note that a <code class=\"structfield\">typelem</code> dependency is considered to imply physical containment of the element type in this type; so DDL changes on the element type might be restricted by the presence of this type.</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typarray</code> <code class=\"type\">oid</code> (references <a class=\"link\" href=\"/docs/18/catalog-pg-type.html\" title=\"52.64. pg_type\"><code class=\"structname\">pg_type</code></a>.<code class=\"structfield\">oid</code>)</p>\n<p>If <code class=\"structfield\">typarray</code> is not zero then it identifies another row in <code class=\"structname\">pg_type</code>, which is the <span class=\"quote\">“<span class=\"quote\">true</span>”</span> array type having this type as element</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typinput</code> <code class=\"type\">regproc</code> (references <a class=\"link\" href=\"/docs/18/catalog-pg-proc.html\" title=\"52.39. pg_proc\"><code class=\"structname\">pg_proc</code></a>.<code class=\"structfield\">oid</code>)</p>\n<p>Input conversion function (text format)</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typoutput</code> <code class=\"type\">regproc</code> (references <a class=\"link\" href=\"/docs/18/catalog-pg-proc.html\" title=\"52.39. pg_proc\"><code class=\"structname\">pg_proc</code></a>.<code class=\"structfield\">oid</code>)</p>\n<p>Output conversion function (text format)</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typreceive</code> <code class=\"type\">regproc</code> (references <a class=\"link\" href=\"/docs/18/catalog-pg-proc.html\" title=\"52.39. pg_proc\"><code class=\"structname\">pg_proc</code></a>.<code class=\"structfield\">oid</code>)</p>\n<p>Input conversion function (binary format), or zero if none</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typsend</code> <code class=\"type\">regproc</code> (references <a class=\"link\" href=\"/docs/18/catalog-pg-proc.html\" title=\"52.39. pg_proc\"><code class=\"structname\">pg_proc</code></a>.<code class=\"structfield\">oid</code>)</p>\n<p>Output conversion function (binary format), or zero if none</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typmodin</code> <code class=\"type\">regproc</code> (references <a class=\"link\" href=\"/docs/18/catalog-pg-proc.html\" title=\"52.39. pg_proc\"><code class=\"structname\">pg_proc</code></a>.<code class=\"structfield\">oid</code>)</p>\n<p>Type modifier input function, or zero if type does not support modifiers</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typmodout</code> <code class=\"type\">regproc</code> (references <a class=\"link\" href=\"/docs/18/catalog-pg-proc.html\" title=\"52.39. pg_proc\"><code class=\"structname\">pg_proc</code></a>.<code class=\"structfield\">oid</code>)</p>\n<p>Type modifier output function, or zero to use the standard format</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typanalyze</code> <code class=\"type\">regproc</code> (references <a class=\"link\" href=\"/docs/18/catalog-pg-proc.html\" title=\"52.39. pg_proc\"><code class=\"structname\">pg_proc</code></a>.<code class=\"structfield\">oid</code>)</p>\n<p>Custom <a class=\"xref\" href=\"/docs/18/sql-analyze.html\" title=\"ANALYZE\"><span class=\"refentrytitle\">ANALYZE</span></a> function, or zero to use the standard function</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typalign</code> <code class=\"type\">char</code></p>\n<p><code class=\"structfield\">typalign</code> is the alignment required when storing a value of this type. It applies to storage on disk as well as most representations of the value inside <span class=\"productname\">PostgreSQL</span>. When multiple values are stored consecutively, such as in the representation of a complete row on disk, padding is inserted before a datum of this type so that it begins on the specified boundary. The alignment reference is the beginning of the first datum in the sequence. Possible values are:</p>\n<div class=\"itemizedlist\">\n<ul class=\"itemizedlist\">\n<li class=\"listitem\">\n<p><code class=\"literal\">c</code> = <code class=\"type\">char</code> alignment, i.e., no alignment needed.</p>\n</li>\n<li class=\"listitem\">\n<p><code class=\"literal\">s</code> = <code class=\"type\">short</code> alignment (2 bytes on most machines).</p>\n</li>\n<li class=\"listitem\">\n<p><code class=\"literal\">i</code> = <code class=\"type\">int</code> alignment (4 bytes on most machines).</p>\n</li>\n<li class=\"listitem\">\n<p><code class=\"literal\">d</code> = <code class=\"type\">double</code> alignment (8 bytes on many machines, but by no means all).</p>\n</li>\n</ul>\n</div>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typstorage</code> <code class=\"type\">char</code></p>\n<p><code class=\"structfield\">typstorage</code> tells for varlena types (those with <code class=\"structfield\">typlen</code> = -1) if the type is prepared for toasting and what the default strategy for attributes of this type should be. Possible values are:</p>\n<div class=\"itemizedlist\">\n<ul class=\"itemizedlist\">\n<li class=\"listitem\">\n<p><code class=\"literal\">p</code> (plain): Values must always be stored plain (non-varlena types always use this value).</p>\n</li>\n<li class=\"listitem\">\n<p><code class=\"literal\">e</code> (external): Values can be stored in a secondary <span class=\"quote\">“<span class=\"quote\">TOAST</span>”</span> relation (if relation has one, see <code class=\"literal\">pg_class.reltoastrelid</code>).</p>\n</li>\n<li class=\"listitem\">\n<p><code class=\"literal\">m</code> (main): Values can be compressed and stored inline.</p>\n</li>\n<li class=\"listitem\">\n<p><code class=\"literal\">x</code> (extended): Values can be compressed and/or moved to a secondary relation.</p>\n</li>\n</ul>\n</div>\n<p><code class=\"literal\">x</code> is the usual choice for toast-able types. Note that <code class=\"literal\">m</code> values can also be moved out to secondary storage, but only as a last resort (<code class=\"literal\">e</code> and <code class=\"literal\">x</code> values are moved first).</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typnotnull</code> <code class=\"type\">bool</code></p>\n<p><code class=\"structfield\">typnotnull</code> represents a not-null constraint on a type. Used for domains only.</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typbasetype</code> <code class=\"type\">oid</code> (references <a class=\"link\" href=\"/docs/18/catalog-pg-type.html\" title=\"52.64. pg_type\"><code class=\"structname\">pg_type</code></a>.<code class=\"structfield\">oid</code>)</p>\n<p>If this is a domain (see <code class=\"structfield\">typtype</code>), then <code class=\"structfield\">typbasetype</code> identifies the type that this one is based on. Zero if this type is not a domain.</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typtypmod</code> <code class=\"type\">int4</code></p>\n<p>Domains use <code class=\"structfield\">typtypmod</code> to record the <code class=\"literal\">typmod</code> to be applied to their base type (-1 if base type does not use a <code class=\"literal\">typmod</code>). -1 if this type is not a domain.</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typndims</code> <code class=\"type\">int4</code></p>\n<p><code class=\"structfield\">typndims</code> is the number of array dimensions for a domain over an array (that is, <code class=\"structfield\">typbasetype</code> is an array type). Zero for types other than domains over array types.</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typcollation</code> <code class=\"type\">oid</code> (references <a class=\"link\" href=\"/docs/18/catalog-pg-collation.html\" title=\"52.12. pg_collation\"><code class=\"structname\">pg_collation</code></a>.<code class=\"structfield\">oid</code>)</p>\n<p><code class=\"structfield\">typcollation</code> specifies the collation of the type. If the type does not support collations, this will be zero. A base type that supports collations will have a nonzero value here, typically <code class=\"symbol\">DEFAULT_COLLATION_OID</code>. A domain over a collatable type can have a collation OID different from its base type's, if one was specified for the domain.</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typdefaultbin</code> <code class=\"type\">pg_node_tree</code></p>\n<p>If <code class=\"structfield\">typdefaultbin</code> is not null, it is the <code class=\"function\">nodeToString()</code> representation of a default expression for the type. This is only used for domains.</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typdefault</code> <code class=\"type\">text</code></p>\n<p><code class=\"structfield\">typdefault</code> is null if the type has no associated default value. If <code class=\"structfield\">typdefaultbin</code> is not null, <code class=\"structfield\">typdefault</code> must contain a human-readable version of the default expression represented by <code class=\"structfield\">typdefaultbin</code>. If <code class=\"structfield\">typdefaultbin</code> is null and <code class=\"structfield\">typdefault</code> is not, then <code class=\"structfield\">typdefault</code> is the external representation of the type's default value, which can be fed to the type's input converter to produce a constant.</p>\n</td>\n</tr>\n<tr>\n<td class=\"catalog_table_entry\">\n<p class=\"column_definition\"><code class=\"structfield\">typacl</code> <code class=\"type\">aclitem[]</code></p>\n<p>Access privileges; see <a class=\"xref\" href=\"/docs/18/ddl-priv.html\" title=\"5.8. Privileges\">Section 5.8</a> for details</p>\n</td>\n</tr>\n</tbody>\n</table>\n</div>\n</div><br class=\"table-break\">\n<div class=\"note\">\n<h3 class=\"title\">Note</h3>\n<p>For fixed-width types used in system tables, it is critical that the size and alignment defined in <code class=\"structname\">pg_type</code> agree with the way that the compiler will lay out the column in a structure representing a table row.</p>\n</div>\n<p><a class=\"xref\" href=\"/docs/18/catalog-pg-type.html#CATALOG-TYPCATEGORY-TABLE\" title=\"Table 52.65. typcategory Codes\">Table 52.65</a> lists the system-defined values of <code class=\"structfield\">typcategory</code>. Any future additions to this list will also be upper-case ASCII letters. All other ASCII characters are reserved for user-defined categories.</p>\n<div class=\"table\" id=\"CATALOG-TYPCATEGORY-TABLE\">\n<p class=\"title\"><strong>Table 52.65. <code class=\"structfield\">typcategory</code> Codes</strong></p>\n<div class=\"table-contents\">\n<table class=\"table\">\n\n\n\n\n<thead>\n<tr>\n<th>Code</th>\n<th>Category</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><code class=\"literal\">A</code></td>\n<td>Array types</td>\n</tr>\n<tr>\n<td><code class=\"literal\">B</code></td>\n<td>Boolean types</td>\n</tr>\n<tr>\n<td><code class=\"literal\">C</code></td>\n<td>Composite types</td>\n</tr>\n<tr>\n<td><code class=\"literal\">D</code></td>\n<td>Date/time types</td>\n</tr>\n<tr>\n<td><code class=\"literal\">E</code></td>\n<td>Enum types</td>\n</tr>\n<tr>\n<td><code class=\"literal\">G</code></td>\n<td>Geometric types</td>\n</tr>\n<tr>\n<td><code class=\"literal\">I</code></td>\n<td>Network address types</td>\n</tr>\n<tr>\n<td><code class=\"literal\">N</code></td>\n<td>Numeric types</td>\n</tr>\n<tr>\n<td><code class=\"literal\">P</code></td>\n<td>Pseudo-types</td>\n</tr>\n<tr>\n<td><code class=\"literal\">R</code></td>\n<td>Range types</td>\n</tr>\n<tr>\n<td><code class=\"literal\">S</code></td>\n<td>String types</td>\n</tr>\n<tr>\n<td><code class=\"literal\">T</code></td>\n<td>Timespan types</td>\n</tr>\n<tr>\n<td><code class=\"literal\">U</code></td>\n<td>User-defined types</td>\n</tr>\n<tr>\n<td><code class=\"literal\">V</code></td>\n<td>Bit-string types</td>\n</tr>\n<tr>\n<td><code class=\"literal\">X</code></td>\n<td><code class=\"type\">unknown</code> type</td>\n</tr>\n<tr>\n<td><code class=\"literal\">Z</code></td>\n<td>Internal-use types</td>\n</tr>\n</tbody>\n</table>\n</div>\n</div><br class=\"table-break\">\n</div>", "manual_path": "catalog-pg-type.html", "comparison_data": {"casts": [], "facts": [{"label": "Catalog name", "value": "pg_catalog.aclitem"}, {"label": "Declared length", "value": "16 bytes"}, {"label": "Documented declaration", "value": "typacl aclitem[] Access privileges; see Section 5.8 for details"}, {"label": "Input function", "value": "aclitemin"}, {"label": "Output function", "value": "aclitemout"}, {"label": "Storage strategy", "value": "plain"}, {"label": "Type OID", "value": "1033"}, {"label": "Type kind", "value": "Base type"}], "ranges": [], "aliases": [], "catalog": {"typacl": "_null_", "typlen": "16", "typelem": "0", "typname": "aclitem", "typsend": "-", "typtype": "b", "typalign": "d", "typarray": "_aclitem", "typbyval": "f", "typdelim": ",", "typinput": "aclitemin", "typmodin": "-", "typndims": "0", "typrelid": "0", "typmodout": "-", "typoutput": "aclitemout", "typtypmod": "-1", "typanalyze": "-", "typdefault": "_null_", "typnotnull": "f", "typreceive": "-", "typstorage": "p", "typbasetype": "0", "typcategory": "U", "typcollation": "0", "typisdefined": "t", "typsubscript": "-", "typdefaultbin": "_null_", "typispreferred": "f", "array_type_name": "_aclitem"}, "operators": [{"oprcom": "0", "oprcode": "aclcontains", "oprjoin": "-", "oprkind": "b", "oprleft": "_aclitem", "oprname": "@>", "oprrest": "-", "oprright": "aclitem", "oprnegate": "0", "oprresult": "bool", "oprcanhash": "f", "oprcanmerge": "f"}, {"oprcom": "0", "oprcode": "aclinsert", "oprjoin": "-", "oprkind": "b", "oprleft": "_aclitem", "oprname": "+", "oprrest": "-", "oprright": "aclitem", "oprnegate": "0", "oprresult": "_aclitem", "oprcanhash": "f", "oprcanmerge": "f"}, {"oprcom": "0", "oprcode": "aclremove", "oprjoin": "-", "oprkind": "b", "oprleft": "_aclitem", "oprname": "-", "oprrest": "-", "oprright": "aclitem", "oprnegate": "0", "oprresult": "_aclitem", "oprcanhash": "f", "oprcanmerge": "f"}, {"oprcom": "=(aclitem,aclitem)", "oprcode": "aclitemeq", "oprjoin": "eqjoinsel", "oprkind": "b", "oprleft": "aclitem", "oprname": "=", "oprrest": "eqsel", "oprright": "aclitem", "oprnegate": "0", "oprresult": "bool", "oprcanhash": "t", "oprcanmerge": "f"}], "operator_classes": [{"opcname": "aclitem_ops", "opcfamily": "hash/aclitem_ops", "opcintype": "aclitem", "opcmethod": "hash", "opcdefault": "t", "opckeytype": "0"}]}, "comparison_hash": "d14c3c90820475f40ae7ff83aab9507f69844d1250d0050141bd838fc8b43e32", "operator_classes": [{"opcname": "aclitem_ops", "opcowner": "POSTGRES", "opcfamily": "hash/aclitem_ops", "opcintype": "aclitem", "opcmethod": "hash", "opcdefault": "t", "opckeytype": "0", "opcnamespace": "pg_catalog"}], "manual_documentation": "catalog schema only"}, "from": "17", "comparison": {"available": true, "changes": [], "prose_changed": true}}