Re: [INTERFACES] Detecting existance of table

Поиск
Список
Период
Сортировка
От José Soares
Тема Re: [INTERFACES] Detecting existance of table
Дата
Msg-id 371F0FC1.DF690C47@sferacarta.com
обсуждение исходный текст
Ответ на Detecting existance of table  ("Brett W. McCoy" <bmccoy@lan2wan.com>)
Список pgsql-interfaces
Try this:
 select TRUE from pg_class where relname = 'my_table' and relkind = 'r';

José


"Brett W. McCoy" ha scritto:

> Is there a way of detecting the existance of a table via a function call?
> I'm trying to implement a 'saved search' feature in a search engine, and
> need to query a database to see if a particular table exists without
> throwing an error.  Actually, can an exception be caught somehow?  I'm
> mainly doing this with PHP3, but I also need to do it via the Perl Pg.pm
>
> Brett W. McCoy
>                                          http://www.lan2wan.com/~bmccoy
> -----------------------------------------------------------------------
> Why is the alphabet in that order?  Is it because of that song?


В списке pgsql-interfaces по дате отправления:

Предыдущее
От: Per Rønne
Дата:
Сообщение: RE: [INTERFACES] Possible error in libpg++ interface, date[time] fields.
Следующее
От: Per Rønne
Дата:
Сообщение: RE: [INTERFACES] Possible error in libpg++ interface, date[time] fields.