Skip to content

Instance Property

psqlTypeName

The Postgres name of this type. This is used for types that don’t have a static OID, like types coming from extensions. The OID is looked up by name the first time the type is used on a connection, if the type can’t be found psqlType is used instead.
var psqlTypeName: String? { get }

Discussion

Use "schema.type" to pick a type from a specific schema, e.g. "ext.ltree". Names are matched exactly as Postgres stores them, so "LTree" won’t find ltree.

The OID is cached per connection, so changing the search_path afterwards doesn’t update it. If the name exists in more than one schema, the connection keeps using the type it found the first time. A qualified name always means the same type.

Default Implementations

PostgresThrowingDynamicTypeEncodable Implementations