]> git.evergreen-ils.org Git - Evergreen.git/commit
LP#1414112: avoid excluding record attribute values that contain only blanks
authorGalen Charlton <gmc@esilibrary.com>
Mon, 26 Jan 2015 16:05:10 +0000 (16:05 +0000)
committerBen Shum <bshum@biblio.org>
Tue, 3 Feb 2015 20:52:56 +0000 (15:52 -0500)
commitde9f5d08537297e236326fa5c7d7d2850d400d3b
tree78e03fcb118daa1d39a0b6dbe49473a7f2f9427b
parentf23109bbfd0dfabc571c840296179cac95b72431
LP#1414112: avoid excluding record attribute values that contain only blanks

Certain record attributes, chiefly the ones whose values comes
from MARC fixed fields and which have a coded value map associated
with them, can have a string consisting of one or more blanks as a
valid value.  Consequently, this patch ensures that
reingest_record_attributes() no longer excludes all attributes that
have blank values from the final attribute list.

This fixes a problem where MARC records with the target audience (008/22)
coded as a blank (unknown or not specified) could no longer be retrieved
using an "audience( )" search filter.

After applying this patch, a reingest of record attributes should be
performed, e.g., by doing

  select metabib.reingest_record_attributes(id)
  from biblio.record_entry
  where not deleted;

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Chris Sharp <csharp@georgialibraries.org>
Signed-off-by: Ben Shum <bshum@biblio.org>
Open-ILS/src/sql/Pg/030.schema.metabib.sql
Open-ILS/src/sql/Pg/t/regress/lp1414112_allow_spaces_as_ff_attr_values.pg [new file with mode: 0644]
Open-ILS/src/sql/Pg/upgrade/XXXX.schema.allow_spaces_as_ff_attr_values.sql [new file with mode: 0644]