Re: Clarification needed

From: Dhanaraj M <Dhanaraj(dot)M(at)Sun(dot)COM>
To: Zdenek Kotala <Zdenek(dot)Kotala(at)Sun(dot)COM>
Cc: Indira Muthuswamy <indumuthu(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Clarification needed
Date: 2006-10-11 15:11:22
Message-ID: 452D099A.1040906@sun.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-hackers

In psql,
psql>\d tableName

Query is

SELECT pg_catalog.format_type(a.atttypid, a.atttypmod) from
pg_attribute a, pg_class c where a.attrelid =c.oid and
c.relname='TableName' and a.attname='ColName';

Zdenek Kotala wrote:

>
> Look at http://www.postgresql.org/docs/8.1/interactive/catalogs.html
>
> Specially on pg_attribute, pg_class and pg_type table. Or you can use
> some features in the psql.
>
> Zdenek
>
>
> Indira Muthuswamy napsal(a):
>
>> Hai,
>>
>> Can anyone of you help me in finding the datatype of a particular
>> column in a table in Postgres?
>>
>> Thanks and Regards,
>> M.Indira
>>
>>
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 5: don't forget to increase your free space map settings

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Andrew Sullivan 2006-10-11 15:18:28 Re: more anti-postgresql FUD
Previous Message Andrew Hammond 2006-10-11 15:02:04 Re: Clarification needed

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Sullivan 2006-10-11 15:18:28 Re: more anti-postgresql FUD
Previous Message Andrew Hammond 2006-10-11 15:02:04 Re: Clarification needed