Re: Enum

From: John R Pierce <pierce(at)hogranch(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Enum
Date: 2009-09-01 23:51:31
Message-ID: 4A9DB383.9030309@hogranch.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Xai wrote:
> Is there a query i can use to get the fields of an Enum, just in case
> someone needs it for the client application.
>

select e.enumlabel from pg_enum as e join pg_type as t on (t.typtype='e'
and e.enumtypeid=t.typbasetype) where t.typname = $1 order by e.enumtypid;

I think. or something close to that.

In response to

  • Enum at 2009-09-01 23:22:18 from Xai

Responses

Browse pgsql-general by date

  From Date Subject
Next Message tanjunhua 2009-09-02 05:31:46 Join efficiency
Previous Message Xai 2009-09-01 23:22:18 Enum