Re: Check if table exists

From: "Leif B(dot) Kristensen" <leif(at)solumslekt(dot)org>
To: pgsql-novice(at)postgresql(dot)org
Subject: Re: Check if table exists
Date: 2009-03-18 17:13:15
Message-ID: 200903181813.15101.leif@solumslekt.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

After some googling, I found a solution here:

<http://www.peterbe.com/plog/pg_class>

IF EXISTS (SELECT relname FROM pg_class WHERE relname='tmp_sources')
THEN

It seems to work ok.
--
Leif Biberg Kristensen | Registered Linux User #338009
Me And My Database: http://solumslekt.org/blog/

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message Semyon Chaichenets 2009-03-18 17:21:23 Re: Check if table exists
Previous Message Leif B. Kristensen 2009-03-18 16:55:37 Check if table exists