pg.ddx.io pgsql-sql@postgresql.org mailing list archive
help / color / mirror / Atom feedHow to Get Column Names from the Table
8+ messages / 6 participants
[nested] [flat]
* How to Get Column Names from the Table
@ 2010-07-07 09:08 venkat <ven.tammineni@gmail.com>
2010-07-07 09:13 ` Re: How to Get Column Names from the Table AI Rumman <rummandba@gmail.com>
2010-07-07 09:14 ` Re: [SQL] How to Get Column Names from the Table Viktor Bojović <viktor.bojovic@gmail.com>
2010-07-07 09:14 ` Re: How to Get Column Names from the Table A. Kretschmer <andreas.kretschmer@schollglas.com>
0 siblings, 3 replies; 8+ messages in thread
From: venkat @ 2010-07-07 09:08 UTC (permalink / raw)
To: pgsql-sql; pgsql-general@postgresql.org
Dear All,
How to get Column Names from Table in PostgreSQL.
Thanks and Regards,
Venkat
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: How to Get Column Names from the Table
2010-07-07 09:08 How to Get Column Names from the Table venkat <ven.tammineni@gmail.com>
@ 2010-07-07 09:13 ` AI Rumman <rummandba@gmail.com>
2010-07-07 09:29 ` Re: How to Get Column Names from the Table Jayadevan M <Jayadevan.Maymala@ibsplc.com>
2 siblings, 1 reply; 8+ messages in thread
From: AI Rumman @ 2010-07-07 09:13 UTC (permalink / raw)
To: venkat <ven.tammineni@gmail.com>; +Cc: pgsql-sql; pgsql-general@postgresql.org
Use:
\d tablename
On Wed, Jul 7, 2010 at 3:08 PM, venkat <ven.tammineni@gmail.com> wrote:
> Dear All,
>
> How to get Column Names from Table in PostgreSQL.
>
> Thanks and Regards,
>
> Venkat
>
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: How to Get Column Names from the Table
2010-07-07 09:08 How to Get Column Names from the Table venkat <ven.tammineni@gmail.com>
2010-07-07 09:13 ` Re: How to Get Column Names from the Table AI Rumman <rummandba@gmail.com>
@ 2010-07-07 09:29 ` Jayadevan M <Jayadevan.Maymala@ibsplc.com>
0 siblings, 0 replies; 8+ messages in thread
From: Jayadevan M @ 2010-07-07 09:29 UTC (permalink / raw)
To: pgsql-general@postgresql.org; pgsql-sql
> Use:
> \d tablename
And what I really like about it is the way you can make a guess about the
table name and use * .
postgres-# \d mt*
Table "public.mt1"
Column | Type | Modifiers
--------+---------+-----------
id | integer |
Table "public.mt2"
Column | Type | Modifiers
--------+---------+-----------
id | integer |
Table "public.mt3"
Column | Type | Modifiers
--------+---------+-----------
id | integer |
Regards,
Jayadevan
DISCLAIMER:
"The information in this e-mail and any attachment is intended only for
the person to whom it is addressed and may contain confidential and/or
privileged material. If you have received this e-mail in error, kindly
contact the sender and destroy all copies of the original communication.
IBS makes no warranty, express or implied, nor guarantees the accuracy,
adequacy or completeness of the information contained in this email or any
attachment and is not liable for any errors, defects, omissions, viruses
or for resultant loss or damage, if any, direct or indirect."
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: [SQL] How to Get Column Names from the Table
2010-07-07 09:08 How to Get Column Names from the Table venkat <ven.tammineni@gmail.com>
@ 2010-07-07 09:14 ` Viktor Bojović <viktor.bojovic@gmail.com>
2010-07-07 10:12 ` Re: [SQL] How to Get Column Names from the Table Sreelatha G <sreetlatha@gmail.com>
2 siblings, 1 reply; 8+ messages in thread
From: Viktor Bojović @ 2010-07-07 09:14 UTC (permalink / raw)
To: venkat <ven.tammineni@gmail.com>; +Cc: pgsql-sql; pgsql-general@postgresql.org
\d tableName
On Wed, Jul 7, 2010 at 11:08 AM, venkat <ven.tammineni@gmail.com> wrote:
> Dear All,
>
> How to get Column Names from Table in PostgreSQL.
>
> Thanks and Regards,
>
> Venkat
>
--
---------------------------------------
Viktor Bojović
---------------------------------------
Wherever I go, Murphy goes with me
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: [SQL] How to Get Column Names from the Table
2010-07-07 09:08 How to Get Column Names from the Table venkat <ven.tammineni@gmail.com>
2010-07-07 09:14 ` Re: [SQL] How to Get Column Names from the Table Viktor Bojović <viktor.bojovic@gmail.com>
@ 2010-07-07 10:12 ` Sreelatha G <sreetlatha@gmail.com>
2010-07-07 10:14 ` Re: [SQL] How to Get Column Names from the Table venkat <ven.tammineni@gmail.com>
0 siblings, 1 reply; 8+ messages in thread
From: Sreelatha G @ 2010-07-07 10:12 UTC (permalink / raw)
To: venkat <ven.tammineni@gmail.com>; +Cc: pgsql-sql; pgsql-general@postgresql.org
Hi,
To get column names only
select column_name from information_schema.columns where
table_name='captor_prime_aggregates';
Thanks
Sreelatha
On Wed, Jul 7, 2010 at 2:44 PM, Viktor Bojović <viktor.bojovic@gmail.com>wrote:
> \d tableName
>
>
> On Wed, Jul 7, 2010 at 11:08 AM, venkat <ven.tammineni@gmail.com> wrote:
>
>> Dear All,
>>
>> How to get Column Names from Table in PostgreSQL.
>>
>> Thanks and Regards,
>>
>> Venkat
>>
>
>
>
> --
> ---------------------------------------
> Viktor Bojović
> ---------------------------------------
> Wherever I go, Murphy goes with me
>
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: [SQL] How to Get Column Names from the Table
2010-07-07 09:08 How to Get Column Names from the Table venkat <ven.tammineni@gmail.com>
2010-07-07 09:14 ` Re: [SQL] How to Get Column Names from the Table Viktor Bojović <viktor.bojovic@gmail.com>
2010-07-07 10:12 ` Re: [SQL] How to Get Column Names from the Table Sreelatha G <sreetlatha@gmail.com>
@ 2010-07-07 10:14 ` venkat <ven.tammineni@gmail.com>
0 siblings, 0 replies; 8+ messages in thread
From: venkat @ 2010-07-07 10:14 UTC (permalink / raw)
To: Sreelatha G <sreetlatha@gmail.com>; +Cc: pgsql-sql; pgsql-general@postgresql.org
Dear Sreelatha.
It is working fine. Thanks alot.
Thanks and Regards,
Venkat
On Wed, Jul 7, 2010 at 3:42 PM, Sreelatha G <sreetlatha@gmail.com> wrote:
> Hi,
>
> To get column names only
>
> select column_name from information_schema.columns where
> table_name='captor_prime_aggregates';
>
> Thanks
> Sreelatha
> On Wed, Jul 7, 2010 at 2:44 PM, Viktor Bojović <viktor.bojovic@gmail.com>wrote:
>
>> \d tableName
>>
>>
>> On Wed, Jul 7, 2010 at 11:08 AM, venkat <ven.tammineni@gmail.com> wrote:
>>
>>> Dear All,
>>>
>>> How to get Column Names from Table in PostgreSQL.
>>>
>>> Thanks and Regards,
>>>
>>> Venkat
>>>
>>
>>
>>
>> --
>> ---------------------------------------
>> Viktor Bojović
>> ---------------------------------------
>> Wherever I go, Murphy goes with me
>>
>
>
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: How to Get Column Names from the Table
2010-07-07 09:08 How to Get Column Names from the Table venkat <ven.tammineni@gmail.com>
@ 2010-07-07 09:14 ` A. Kretschmer <andreas.kretschmer@schollglas.com>
2010-07-07 09:17 ` Re: How to Get Column Names from the Table venkat <ven.tammineni@gmail.com>
2 siblings, 1 reply; 8+ messages in thread
From: A. Kretschmer @ 2010-07-07 09:14 UTC (permalink / raw)
To: pgsql-sql
In response to venkat :
> Dear All,
>
> How to get Column Names from Table in PostgreSQL.
select column_name from information_schema.columns where table_name = 'your_table';
Regards, Andreas
--
Andreas Kretschmer
Kontakt: Heynitz: 035242/47150, D1: 0160/7141639 (mehr: -> Header)
GnuPG: 0x31720C99, 1006 CCB4 A326 1D42 6431 2EB0 389D 1DC2 3172 0C99
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: How to Get Column Names from the Table
2010-07-07 09:08 How to Get Column Names from the Table venkat <ven.tammineni@gmail.com>
2010-07-07 09:14 ` Re: How to Get Column Names from the Table A. Kretschmer <andreas.kretschmer@schollglas.com>
@ 2010-07-07 09:17 ` venkat <ven.tammineni@gmail.com>
0 siblings, 0 replies; 8+ messages in thread
From: venkat @ 2010-07-07 09:17 UTC (permalink / raw)
To: A. Kretschmer <andreas.kretschmer@schollglas.com>; +Cc: pgsql-sql
Thanks alot Andreas...It is working fine...
Thanks again.
Venkat
On Wed, Jul 7, 2010 at 2:44 PM, A. Kretschmer <
andreas.kretschmer@schollglas.com> wrote:
> In response to venkat :
> > Dear All,
> >
> > How to get Column Names from Table in PostgreSQL.
>
> select column_name from information_schema.columns where table_name =
> 'your_table';
>
>
> Regards, Andreas
> --
> Andreas Kretschmer
> Kontakt: Heynitz: 035242/47150, D1: 0160/7141639 (mehr: -> Header)
> GnuPG: 0x31720C99, 1006 CCB4 A326 1D42 6431 2EB0 389D 1DC2 3172 0C99
>
> --
> Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-sql
>
^ permalink raw reply [nested|flat] 8+ messages in thread
end of thread, other threads:[~2010-07-07 10:14 UTC | newest]
Thread overview: 8+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2010-07-07 09:08 How to Get Column Names from the Table venkat <ven.tammineni@gmail.com>
2010-07-07 09:13 ` AI Rumman <rummandba@gmail.com>
2010-07-07 09:29 ` Jayadevan M <Jayadevan.Maymala@ibsplc.com>
2010-07-07 09:14 ` Viktor Bojović <viktor.bojovic@gmail.com>
2010-07-07 10:12 ` Sreelatha G <sreetlatha@gmail.com>
2010-07-07 10:14 ` venkat <ven.tammineni@gmail.com>
2010-07-07 09:14 ` A. Kretschmer <andreas.kretschmer@schollglas.com>
2010-07-07 09:17 ` venkat <ven.tammineni@gmail.com>
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