evergreen.protect_reserved_rows_from_delete() trigger function returning error
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Evergreen |
Fix Released
|
High
|
Unassigned | ||
2.9 |
Fix Released
|
High
|
Unassigned |
Bug Description
The fix for bug 1513554 included creating a general trigger function to prevent the deletion of reserved table rows with an ID lower than a specified threshold. Testing for that seemed to pass muster, but I'm now seeing a problem when deleting rows that *can* be deleted (i.e., with IDs higher than the threshold). Steps:
1) create a new Acquisitions cancel reason by going to Admin -> Acquisitions Administration -> Cancel Reasons and clicking "New Cancel Reason".
2) check the box beside the new reason and click "Delete Selected".
Expected behavior is that the screen removes the deleted reason from the list. What happens is nothing. The error message in the logs is:
ERROR: control reached end of trigger procedure without RETURN
CONTEXT: PL/pgSQL function protect_
STATEMENT: DELETE FROM acq.cancel_reason WHERE id = 2142;
I'm working on a fix right now.
Evergreen 2.9 through current master
OpenSRF current
PostgreSQL 9.4
Ubuntu 14.04
Changed in evergreen: | |
importance: | Undecided → High |
assignee: | nobody → Chris Sharp (chrissharp123) |
Changed in evergreen: | |
status: | Fix Committed → Fix Released |
Branch available for testing/signoff:
http:// git.evergreen- ils.org/ ?p=working/ Evergreen. git;a=commit; h=e8b63566c79a9 519ac0dd4908f05 293a9a02913d