Checking for table existence - Mailing list pgsql-sql

From Julester
Subject Checking for table existence
Date
Msg-id prso7.50245$f7.6232115@news02.optonline.net
Whole thread Raw
Responses Re: Checking for table existence
Re: Checking for table existence
Re: Checking for table existence
Re: Checking for table existence
List pgsql-sql
Hi everyone.  In my old SQL Server days, I used a command such as "IF
exists(select name from sys_objects where name = 'xyztable')"  to check if a
table existed before creating it with a standard CREATE command.  I looked
in the PostgreSQL documentation, but for the life of me, I can't find an
equivalent.  I can view if the table exists by doing a select against the
meta-data tables, but what about the IF statement ?  Any help would be
greatly appreciated.  Thanks.


Julester






pgsql-sql by date:

Previous
From: degoble@sgtech (David. E. Goble)
Date:
Subject: I could do with some guidance
Next
From: ke wang
Date:
Subject: How to see the definition of an existing table?