asset.copy_vis_attr_cache upgrade script includes deleted items

Bug #1731281 reported by Jason Boyer
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Evergreen
Fix Released
Medium
Unassigned

Bug Description

Eg 3.0

With bug 1698206 we can drop staged search thanks due in part to the asset.copy_vis_attr_cache table. Unfortunately, the upgrade script forgot to exclude deleted copies when generating the table. The triggers that maintain the table are fine but the deleted copies need to be removed to prevent "phantom" search results.

The presence of an entry in this table can cause inaccurate "X of Y copies available at $location" in search results when copies were deleted before the upgrade script was run. This is especially annoying when *all* copies were deleted and users are looking for titles that don't exist.

Quick branch incoming.

Tags: pullrequest
Revision history for this message
Jason Boyer (jboyer) wrote :

Branching out:
http://git.evergreen-ils.org/?p=working/Evergreen.git;a=shortlog;h=refs/heads/user/jboyer/lp1731281-acvac-cleanup

Testing:
make sure there's at least one entry in the asset.copy_vis_attr_cache for an item that has been deleted attached to a record that the owning library no longer holds any copies of. A search for that title at that library will return the record with no holdings and the message "1 of 1 available" (numbers depending on how many deleted copies from that ou were attached.)

After running script, the record above will no longer appear in search results scoped to locations where all remaining copies were deleted.

tags: added: pullrequest
Revision history for this message
Galen Charlton (gmc) wrote :

Tested and pushed to master and rel_3_0. Thanks, Jason!

Changed in evergreen:
status: New → Confirmed
milestone: none → 3.0.2
importance: Undecided → Medium
assignee: nobody → Galen Charlton (gmc)
status: Confirmed → Fix Committed
assignee: Galen Charlton (gmc) → nobody
Changed in evergreen:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.