Back to bug 32950

Who When What Removed Added
katrin.fischer 2023-02-13 19:16:51 UTC Severity minor normal
Summary marc modification template moving subfield can lose values for repeatable fields MARC modification template moving subfield can lose values for repeatable fields
martin.renvoize 2023-03-17 11:02:16 UTC CC martin.renvoize, nick
martin.renvoize 2023-07-26 12:58:37 UTC CC katrin.fischer
janet.mcgowan 2025-09-10 13:09:26 UTC CC janet.mcgowan
martin.renvoize 2025-09-23 09:51:52 UTC Status NEW Needs Signoff
Assignee koha-bugs martin.renvoize
martin.renvoize 2025-09-23 09:53:11 UTC Version 21.11 Main
martin.renvoize 2025-10-01 12:34:30 UTC Keywords Manual
martin.renvoize 2025-10-01 12:34:48 UTC Patch complexity --- Small patch
martin.renvoize 2025-10-01 12:37:08 UTC Attachment #187184 Attachment is obsolete 0 1
martin.renvoize 2025-10-01 12:37:19 UTC Attachment #187185 Attachment is obsolete 0 1
martin.renvoize 2025-10-01 12:39:04 UTC Attachment #186781 Attachment is obsolete 0 1
martin.renvoize 2025-10-01 12:39:06 UTC Attachment #186782 Attachment is obsolete 0 1
martin.renvoize 2025-10-01 12:39:15 UTC Status Needs Signoff Signed Off
martin.renvoize 2025-10-01 12:39:28 UTC Comment 5 Tag important
martin.renvoize 2025-10-01 12:39:58 UTC Comment 6 Tag obsolete
martin.renvoize 2025-10-01 12:40:04 UTC Comment 7 Tag obsolete
martin.renvoize 2025-10-01 12:40:09 UTC Comment 8 Tag important
martin.renvoize 2025-10-01 12:40:13 UTC Comment 9 Tag important
martin.renvoize 2025-10-01 12:40:23 UTC Comment 0 Tag obsolete
martin.renvoize 2025-10-01 12:40:25 UTC Comment 2 Tag obsolete
martin.renvoize 2025-10-01 12:40:28 UTC Comment 3 Tag obsolete
jonathan.druart 2025-10-06 09:29:33 UTC Keywords release-notes-needed
CC jonathan.druart
jonathan.druart 2025-10-06 09:30:18 UTC Status Signed Off Passed QA
jonathan.druart 2025-10-06 09:30:21 UTC Attachment #187186 Attachment is obsolete 0 1
Attachment #187187 Attachment is obsolete 0 1
lucas 2025-10-06 15:16:30 UTC Status Passed QA Pushed to main
Version(s) released in 25.11.00
lucas 2025-10-06 17:12:30 UTC CC lucas
Keywords additional_work_needed
martin.renvoize 2025-10-07 16:57:47 UTC Status Pushed to main Passed QA
martin.renvoize 2025-10-07 16:59:09 UTC Text to go in the release notes MARC modification templates now correctly preserve existing values when moving subfields within repeatable fields. Previously, causing data loss.

**What's fixed:**

- Existing subfield values in fields that don't contain the source subfield are now preserved
- Source subfield values are only moved to the corresponding target positions in fields that actually contain the, those existing $a values would be overwritten or lost.

**Example scenario:**

Given multiple 020 fields:
- 020$a with existing ISBN
- 020$a with another existing ISBN
- 020$z with cancelled ISBN (to be moved to $a)
- 020$z with another, moving subfields could cause data loss or duplication when the source subfield didn't exist in all instances of the repeatable field.

**The problem:**

When using a MARC modification template to move a subfield within a repeatable field (for source subfield
- The move operation correctly removes the source subfields after copying their values
- Field order and other subfields are maintained correctly

**For cataloguers:**

MARC modification template "move" operations now work reliably cancelled ISBN (to be moved to $a)

Previously, when moving 020$z to 020$a, the first two existing 020$a values would be replaced with values from the 020$z fields example, moving 020$z to 020$a), if some 020 fields had existing $a values but no $z values with repeatable fields. When moving subfields, only the fields that contain the source subfield will be affected, and all other existing values in the repeatable fields will be preserved.
martin.renvoize 2025-10-07 16:59:18 UTC Keywords additional_work_needed, release-notes-needed
lucas 2025-10-07 17:02:10 UTC Status Passed QA Pushed to main
paul.derscheid 2025-10-23 21:10:34 UTC Status Pushed to main Pushed to stable
Version(s) released in 25.11.00 25.11.00,25.05.05

Back to bug 32950