From: | Craig Ringer <craig(at)postnewspapers(dot)com(dot)au> |
---|---|
To: | Abdul Rahman <abr_ora(at)yahoo(dot)com> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: Key Vs Index |
Date: | 2009-02-11 07:31:52 |
Message-ID: | 49927EE8.9010005@postnewspapers.com.au |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Abdul Rahman wrote:
>
> In Oracle, the index is automatically created during the creation of
> Primary Key.
The same is true in PostgreSQL. For example, here's a message from a
recent job I ran that created a temp table with SELECT ... INTO and
added a primary key to it:
psql:import_checks.sql:79: NOTICE: ALTER TABLE / ADD PRIMARY KEY will
create implicit index "check_weeks_pkey" for table "check_weeks"
Can you give an example of what you are talking about?
> But in PostgreSQL either index is implicitly created
Is "implicitly" in some way intended to mean something distinct to
"automatically"?
> I don't find any index against Primary
> Key and have to create index on this key.
AFAIK you CAN NOT have a PRIMARY KEY in PostgreSQL without an associated
unique index.
--
Craig Ringer
From | Date | Subject | |
---|---|---|---|
Next Message | Scott Marlowe | 2009-02-11 07:32:04 | Re: Key Vs Index |
Previous Message | Scott Marlowe | 2009-02-11 07:17:49 | Re: Intel SSD |