Re: DB creation script questions

Поиск
Список
Период
Сортировка
От Andrew Sullivan
Тема Re: DB creation script questions
Дата
Msg-id 20060816191039.GF25228@phlogiston.dyndns.org
обсуждение исходный текст
Ответ на DB creation script questions  ("Jon Horsman" <horshaq@gmail.com>)
Список pgsql-sql
On Wed, Aug 16, 2006 at 02:44:58PM -0400, Jon Horsman wrote:
> I have previously used MySQL and was able to accomplish this very
> simply using IF NOT EXISTS for the table and database creation but
> this doesn't seem to be available for postgres and i'm looking for a
> more robust solution anyways.

Well, you could query the SQL-standard Information Schema. 
Alternatively, you can query the system tables like pg_class.  But if
you want the more standard one, use the tables under schema
information_schema.  That's the reason there's a standard.

A

-- 
Andrew Sullivan  | ajs@crankycanuck.ca
This work was visionary and imaginative, and goes to show that visionary
and imaginative work need not end up well.     --Dennis Ritchie


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

Предыдущее
От: Andrew Sullivan
Дата:
Сообщение: Re: OT: OpenDatabase Model ?
Следующее
От: "Jesper K. Pedersen"
Дата:
Сообщение: Re: OT: OpenDatabase Model ?