Re: Automatically parsing in-line composite types - Mailing list pgsql-general

From Mitar
Subject Re: Automatically parsing in-line composite types
Date
Msg-id CAKLmikMp3z29F4OPjkyHc-qbcwhSx_OFXBz5bPFoa=-vqufR7Q@mail.gmail.com
Whole thread Raw
In response to Re: Automatically parsing in-line composite types  (Dave Cramer <pg@fastcrypt.com>)
List pgsql-general
Hi!

On Tue, Oct 29, 2019 at 5:23 AM Dave Cramer <pg@fastcrypt.com> wrote:
> Reading the RowDescription is the only way I am aware of.

But that provides only the types for the top-level fields. Not the
inline composite types. If your top-level field is a registered
composite type then yes, it works out if you then go and read from
system tables definitions of those types. But for any other case where
you for example subselect a list of columns from a table in a
sub-query, it does not work out.

I think ideally, with introduction of composite types into PostgreSQL,
RowDescription should have been extended to provide information for
composite types as well, recursively. In that way you would not even
have to go and fetch additional information from other types,
potentially hitting race conditions.


Mitar

-- 
http://mitar.tnode.com/
https://twitter.com/mitar_m



pgsql-general by date:

Previous
From: Fabio Ugo Venchiarutti
Date:
Subject: Re: Automatically parsing in-line composite types
Next
From: Mitar
Date:
Subject: Re: Automatically parsing in-line composite types