Search Postgresql Archives

Re: Normal errors codes in serializable transactions

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

> In PostgreSQL, 40001 is used for serialization failures due to MVCC

> issues, and 40P01 is used for serialization failures due to
> deadlocks.  I think that many years back when PostgreSQL moved to
> MVCC it was judged important to differentiate between them with
> different SQLSTATE values because deadlocks tend to be somewhat
> more problematic.  Had I been involved with PostgreSQL at the time,
> I would have argued the value of staying with the standard
> serialization failure SQLSTATE (40001) for both, but it is unlikely
> to be changed at this point.  From the application perspective,
> both can (and generally should) be treated as meaning that there
> was nothing wrong with the transaction in itself; it only failed
> because of conflicts with one or more concurrent transactions and
> is likely to succeed if retried from the start.

Thank you very much for the prompt and informative reply!
That clears up my doubt.  For future reference: both 40001
and 40P01 are "normal" errors when issuing SERIALIZABLE
transactions in a concurrent setting...

Best,
Jon



-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general





[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux