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

regclass without error?

From: Tatsuo Ishii <ishii(at)postgresql(dot)org>
To: pgsql-hackers(at)postgresql(dot)org
Subject: regclass without error?
Date: 2010-09-03 08:28:35
Message-ID: (view raw or whole thread)
Lists: pgsql-hackers

Is there any way to use regclass without having ERROR?

pgpool-II needs to find the oid from table name and for the purpose it
issues something like "SELECT 'table_name'::regproc::oid". Problem is,
if the table does not exist, an error occured and the transaction
aborts. Ideally if the table does not exist, the SELECT returns 0

Any idea?
Tatsuo Ishii
SRA OSS, Inc. Japan


pgsql-hackers by date

Next:From: Heikki LinnakangasDate: 2010-09-03 09:33:43
Subject: Re: Synchronous replication - patch status inquiry
Previous:From: Pavel StehuleDate: 2010-09-03 08:16:12
Subject: Re: thousand unrelated data files in pg_default tablespace

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