| From: | personal(at)rysmax(dot)com |
|---|---|
| To: | pgsql-bugs(at)postgresql(dot)org |
| Cc: | personal(at)rysmax(dot)com |
| Subject: | BUG #14909: nextval() bug |
| Date: | 2017-11-15 10:51:36 |
| Message-ID: | 20171115105136.1473.62937@wrigleys.postgresql.org |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-bugs |
The following bug has been logged on the website:
Bug reference: 14909
Logged by: Max Rys
Email address: personal(at)rysmax(dot)com
PostgreSQL version: 10.1
Operating system: macOS 10.12.6
Description:
I run this simple queries on PostgeSQL 9.6 and 10.1:
DROP TABLE IF EXISTS "user";
CREATE TABLE "user" (
id serial primary key not null,
email varchar(64) not null
);
INSERT INTO "user" (id, email) VALUES ('1', 'admin(at)example(dot)com');
INSERT INTO "user" (id, email) VALUES ('2', 'user(at)example(dot)com');
All done without errors.
When i try to run the query bellow:
INSERT INTO "user" (email) VALUES ('test(at)example(dot)com');
and got the next error in pgAdmin and from the PHP:
ERROR: duplicate key value violates unique constraint "user_pkey"
DETAIL: Key (id)=(1) already exists.
but when i try to run this query 2 times the query executed without errors
on 3rd time.
I think this is a bug in nextval() function.
| From | Date | Subject | |
|---|---|---|---|
| Next Message | hubert depesz lubaczewski | 2017-11-15 11:26:08 | Re: BUG #14909: nextval() bug |
| Previous Message | Jeevan Chalke | 2017-11-15 09:06:43 | Re: [BUGS] BUG #14890: Error grouping by same column twice using FDW |