Backport patch to preserve SQLSTATE in PL/python.
We had backported PL/python from PostgreSQL 9.1, but not this patch that was applied later to the stable branch. I noticed when I started looking at this, while cleaning up the source file/line number information in error messages. I did not backport the regression test changes, because we had apparently not backported other regression test changes either, and I was not able to make the tests work easily. Original commit: commit d2192a108c7b118d430f03cff0ff84861d5026e0 Author: Heikki Linnakangas <heikki.linnakangas@iki.fi> Date: Thu Nov 24 17:18:43 2011 +0200 Preserve SQLSTATE when an SPI error is propagated through PL/python exception handler. This was a regression in 9.1, when the capability to catch specific SPI errors was added, so backpatch to 9.1. Mika Eloranta, with some editing by Jan Urbański.
Showing
想要评论请 注册 或 登录