huh!? - Mailing list pgsql-bugs

From Vlad Marchenko
Subject huh!?
Date
Msg-id 017f01c1d71b$e41a9240$962805c3@mv
Whole thread Raw
Responses Re: huh!?
List pgsql-bugs
Good day. Please reveiew log below.

test=# \d subscribers;
                                  Table "subscribers"
  Column  |          Type          |                     Modifiers
----------+------------------------+----------------------------------------
-----------
 sid      | bigint                 | not null default
nextval('subscribers_sid'::text)
 email    | character varying(128) | not null default ''
 domain   | character varying(128) | not null default ''
 status   | smallint               | default 0
 password | character varying(128) | not null default ''
 signup   | date                   | default '2002-01-01'
 name     | character varying(128) | default ''
 sex      | character varying(1)   | default ''
 address  | character varying(128) | default ''
 city     | character varying(128) | default ''
 state    | character varying(2)   | default ''
 zip      | character varying(16)  | not null default ''
 country  | character varying(2)   | default ''
 phone    | character varying(128) | not null default ''
Indexes: subs_domain_idx
Primary key: subscribers_pkey
Unique keys: subscribers_email_key
Triggers: RI_ConstraintTrigger_63057,
          RI_ConstraintTrigger_63063,
          RI_ConstraintTrigger_63069,
          RI_ConstraintTrigger_63161,
          RI_ConstraintTrigger_63163

test=# select count(*) from subscribers;
 count
-------
 96856
(1 row)

test=# select * from subscribers where email~'domain4';
 sid | email | domain | status | password | signup | name | sex | address |
city | state | zip | country | phone
-----+-------+--------+--------+----------+--------+------+-----+---------+-
-----+-------+-----+---------+-------
(0 rows)

test=# INSERT INTO subscribers(email) SELECT (random()||'@domain4.com') from
subscribers;
ERROR:  Cannot insert a duplicate key into unique index
subscribers_email_key
test=#


I assume that this is because of pure transaction data isolation?

---
 Best Regards,

 Vlad Marchenko

 -------------------------------------------------------
 TrackingSoft LLC
 http://trackingsoft.com/  http://affiliatetracking.net/

pgsql-bugs by date:

Previous
From: Joe Piscitella
Date:
Subject: Solaris 8 install of postgres 7.2
Next
From: "Vlad Marchenko"
Date:
Subject: Re: huh!?