BUG #8127: After failed insert a select to figure out what failed is rejected

Поиск
Список
Период
Сортировка
От matti.aarnio@methics.fi
Тема BUG #8127: After failed insert a select to figure out what failed is rejected
Дата
Msg-id E1UWmBX-0006ES-MB@wrigleys.postgresql.org
обсуждение исходный текст
Ответы Re: BUG #8127: After failed insert a select to figure out what failed is rejected  (Amit Kapila <amit.kapila@huawei.com>)
Список pgsql-bugs
The following bug has been logged on the website:

Bug reference:      8127
Logged by:          Matti Aarnio
Email address:      matti.aarnio@methics.fi
PostgreSQL version: 9.2.4
Operating system:   Fedora 18
Description:        =


With table:

  CREATE TABLE demo (
     pkey INTEGER PRIMARY KEY,
     key2 VARCHAR UNIQUE,
     key3 VARCHAR UNIQUE
  );

An insert that fails secondary constraint key does return SQL State 23505,
and maybe an explanation message telling that "Key (key3)=3D".. " is
duplicate."

With Oracle we ask a SELECT after such an error on that table for all
possibly existing secondary keys values, and get them to report detailed
conflict information.

With PostgreSQL we get following error on those error analysis SELECTs:
  ERROR: current transaction is aborted,
commands ignored until end of transaction block

Could PostgreSQL be similarly permissive (with respect of Oracle) allowing
SELECTs within same transaction context that was already rejected?

В списке pgsql-bugs по дате отправления:

Предыдущее
От: pradip29@gmail.com
Дата:
Сообщение: BUG #8125: server connecting error
Следующее
От: whiplash
Дата:
Сообщение: Re: BUG #8118: Wrong sorting text