Skip site navigation (1) Skip section navigation (2)

Checking for existence of table

From: Paul McGarry <paulm(at)opentec(dot)com(dot)au>
To: pgsql-sql(at)hub(dot)org
Subject: Checking for existence of table
Date: 2000-07-11 07:28:33
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-sql

Is it possible to check for the existence of a table within PL/pgSQL?

select count(*) from pg_class where relname='name' and 
be the answer to this question?

Paul McGarry            mailto:paulm(at)opentec(dot)com(dot)au 
Systems Integrator 
Opentec Pty Ltd
6 Lyon Park Road        Phone: (02) 9878 1744 
North Ryde NSW 2113     Fax:   (02) 9878 1755

pgsql-sql by date

Next:From: Volker PaulDate: 2000-07-11 07:31:49
Subject: Change type of column
Previous:From: Adam WalczykiewiczDate: 2000-07-11 07:16:19
Subject: SQL-92 SQLSTATE in PostgreSQL ?!

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group