From: Thomas Kellerer <spam_eater@gmx.net>
To: pgsql-bugs@postgresql.org
Subject: Re: Weird message when creating PK constraint named like table
Date: Thu, 12 Jan 2012 14:45:34 +0100
Message-ID: <jemo3n$eab$1@dough.gmane.org> (raw)
In-Reply-To: <4F0D99AB02000025000446C9@gw.wicourts.gov>
References: <CALtFtELrOJ-V0wuke++S7C1_XvDiJ9irBtnuecjLMq4d7zhhTg@mail.gmail.com>
<4F0D99AB02000025000446C9@gw.wicourts.gov>
Kevin Grittner, 11.01.2012 21:16:
>> When I do this
>>
>> CREATE TABLE "*T1*"
>> (
>> "T1_ID" bigint NOT NULL,
>> CONSTRAINT "*T1*" PRIMARY KEY ("T1_ID" )
>> );
>>
>>
>> I get the following message:
>>
>> NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index
>> "T1" for table "T1"
>> ERROR: relation "T1" already exists
>
>> SQL state: 42P07
>
> Hmm. If I create them with the asterisks as part of the relation
> names, I see the asterisks in the messages:
>
> NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index
> "*T1*" for table "*T1*"
> ERROR: relation "*T1*" already exists
>
The * around the table name was added by the translation from the HTML to a plain text email.
If you display the HTML version of the original posting the name is written in bold, and I gues the plain text "converter" simply adds the asterisks as that is the usual convention for bold in plain text emails.
The original SQL is:
CREATE TABLE "T1"
(
"T1_ID" bigint NOT NULL,
CONSTRAINT "T1" PRIMARY KEY ("T1_ID" )
);
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-bugs@postgresql.org
Cc: spam_eater@gmx.net
Subject: Re: Weird message when creating PK constraint named like table
In-Reply-To: <jemo3n$eab$1@dough.gmane.org>
References: <CALtFtELrOJ-V0wuke++S7C1_XvDiJ9irBtnuecjLMq4d7zhhTg@mail.gmail.com> <4F0D99AB02000025000446C9@gw.wicourts.gov> <jemo3n$eab$1@dough.gmane.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox