Re: Search system catalog for mystery type - Mailing list pgsql-general

From Alvaro Herrera
Subject Re: Search system catalog for mystery type
Date
Msg-id 20091104205734.GJ3531@alvh.no-ip.org
Whole thread Raw
In response to Search system catalog for mystery type  ("Carlo Stonebanks" <stonec.register@sympatico.ca>)
Responses Re: Search system catalog for mystery type
List pgsql-general
Carlo Stonebanks wrote:
> When I try the following command:
> ALTER TABLE mdx_core.audit_impt RENAME TO _audit_impt;
>
> I get the error message:
>
> ERROR: type "_audit_impt" already exists
> SQL state: 42710

Probably the easiest way around this is to use two underscores instead
of one:

ALTER TABLE mdx_core.audit_impt RENAME TO __audit_impt;

Or any other char for that matter -- you picked the only one that would
cause a problem.  Even a space should be fine:

ALTER TABLE mdx_core.audit_impt RENAME TO " audit_impt";

(Not sure I can recommend this though)

--
Alvaro Herrera                                http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support

pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: Search system catalog for mystery type
Next
From: Raimon Fernandez
Date:
Subject: Where I can find "SSL specification"?