LP#1116509: prevent null SVF attribute value from breaking record import user/gmcharlt/lp1116509_handle_null_svf_during_import
authorGalen Charlton <gmc@esilibrary.com>
Tue, 5 Feb 2013 18:12:02 +0000 (13:12 -0500)
committerGalen Charlton <gmc@esilibrary.com>
Tue, 5 Feb 2013 18:15:46 +0000 (13:15 -0500)
commitf1487091e89043bb931e11d524dcb4a31af8ecd7
tree50c6277e8fea493b48d1b8c0675e522249cc0bb4
parent10114e3aeb26341f3441ebff6e3a102b2fcc1ea5
LP#1116509: prevent null SVF attribute value from breaking record import

Fix problem where a record could fail to be staged for import
with the following error:

ERROR: query string argument of EXECUTE is null
CONTEXT: PL/pgSQL function "extract_rec_attrs" line 72 at EXECUTE statement
SQL function "extract_rec_attrs" statement 1

This error would be triggered if at least one SVF attribute has a normalization
function defined that is applied to a null value during record import.

Patch is based on a suggestion by Bob Wicksall.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Open-ILS/src/sql/Pg/012.schema.vandelay.sql
Open-ILS/src/sql/Pg/upgrade/XXXX.handle_null_svf_during_import.sql [new file with mode: 0644]