Re: sql scripts - Mailing list pgsql-admin

From David F. Skoll
Subject Re: sql scripts
Date
Msg-id Pine.LNX.4.58.0310201329190.5848@shishi.roaringpenguin.com
Whole thread Raw
In response to sql scripts  (Sam Carleton <ehc@linux-info.net>)
List pgsql-admin
On Sat, 18 Oct 2003, Sam Carleton wrote:

> I am working on creating my first database in Postgres.  In the
> script that will create all the tables for the firs time, I would
> like to have a conditional statement to delete a table, if it
> already exists.

As far as I know, there is no way to do that in PostgreSQL's standard
SQL language.  But it doesn't matter -- as long as the DROP TABLE
command is in it's own transaction, you can unconditionally drop the table
and ignore any errors.

Regards,

David.

pgsql-admin by date:

Previous
From: Andrew Sullivan
Date:
Subject: Re: ERserver problems
Next
From: "scott.marlowe"
Date:
Subject: Re: Postgresql Memory Problem