pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Laurenz Albe <laurenz.albe@cybertec.at>
To: a <372660931@qq.com>
To: pgsql-general <pgsql-general@postgresql.org>
Subject: Re: How can I retrieve attribute category with attribute Oid in C function?
Date: Mon, 14 May 2018 10:11:35 +0200
Message-ID: <1526285495.2675.10.camel@cybertec.at> (raw)
In-Reply-To: <tencent_1848C2CD1C95FC5161268968@qq.com>
References: <tencent_1848C2CD1C95FC5161268968@qq.com>

a wrote:
> Hi I am writing something that would need to identify the attribute category inside a C function,
> now I may need a way of fast access it, but the information is not stored in FormData_pg_attribute structure.

Are you talking about pg_type.typcategory?

That is accessible from FormData_pg_type.
You'd have to look up atttypid in the TYPEOID cache.

Yours,
Laurenz Albe
-- 
Cybertec | https://www.cybertec-postgresql.com




view thread (5+ messages)  latest in thread

Message-ID: <1526285495.2675.10.camel@cybertec.at>
Permalink:  ../1526285495.2675.10.camel@cybertec.at/
Also on:    postgresql.org/message-id/1526285495.2675.10.camel@cybertec.at

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: laurenz.albe@cybertec.at, 372660931@qq.com
  Subject: Re: How can I retrieve attribute category with attribute Oid in C function?
  In-Reply-To: <1526285495.2675.10.camel@cybertec.at>
  References: <tencent_1848C2CD1C95FC5161268968@qq.com> <1526285495.2675.10.camel@cybertec.at>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox