Search Postgresql Archives

Re: existence of column name

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Tried this out, and got a very familiar error that I don't know what to do with : "Error: expected just one rule action".

I'm using 8.3.5, and see this error quite a bit. Anyone know what's behind this error?

Thanks,
Eric

On Apr 8, 2009, at 8:54 PM, John R Pierce wrote:

Eric Smith wrote:
All,

From the C API, how do I check for the existence of a column name in a given table?

select data_type from information_schema.columns where table_schema='public' and table_name='given_table' and column_name='some_column';

that will return the data_type if the column exists, or return zero rows if it doesn't.




--
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux