Re: [GENERAL] column name with plpgsql

2009-02-07 Thread Alain Roger
Thanks a lot Raymond it works well. On Sat, Feb 7, 2009 at 3:32 PM, Raymond O'Donnell wrote: > On 07/02/2009 14:26, Alain Roger wrote: > > > i have a table which can be altered with several additional column. How > can > > i test under plpgsql if a particular column already exists ? > > select 1

Re: [GENERAL] column name with plpgsql

2009-02-07 Thread Raymond O'Donnell
On 07/02/2009 14:26, Alain Roger wrote: > i have a table which can be altered with several additional column. How can > i test under plpgsql if a particular column already exists ? select 1 from information_schema.columns where table_name = 'your_table_name_here' and column_name = 'your_colum

Re: [GENERAL] column name with plpgsql

2009-02-07 Thread Grzegorz Jaƛkiewicz
information_schema is the keyword here. -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] column name with plpgsql

2009-02-07 Thread Alain Roger
Hi, i have a table which can be altered with several additional column. How can i test under plpgsql if a particular column already exists ? thx. -- Alain --- Windows XP x64 SP2 / Fedora 10 KDE 4.2 PostgreSQL 8.3.5 / MS SQL server 2005 Apac