Bug 23009

Summary: Add -deleted_marc_conditions argument to export_records script
Product: Koha Reporter: David Gustafsson <glasklas>
Component: Command-line UtilitiesAssignee: David Gustafsson <glasklas>
Status: BLOCKED --- QA Contact: Testopia <testopia>
Severity: enhancement    
Priority: P5 - low CC: robin
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:
Bug Depends on: 20551    
Bug Blocks:    
Attachments: Bug 23009: Add -deleted_marc_conditions to export_records
Bug 23009: Add -set_deleted_marc_conditions to export_records
Bug 23009: Add -set_deleted_marc_conditions to export_records

Description David Gustafsson 2019-05-29 13:56:40 UTC
At our library we need to be able to marc exported records for deletion depending on a marc conditions. This patch adds a new argument that provides that functionality. The tests t/db_dependent/Exporter/Record.t fails in current master, which is an issue when running the included tests, but it seems like an unrelated bug. I will look into it and create a separate issue regarding this.
Comment 1 David Gustafsson 2019-05-29 14:21:20 UTC
Created attachment 90189 [details] [review]
Bug 23009: Add -deleted_marc_conditions to export_records

Add -deleted_marc_conditions argument to export_records script
for setting deleted flag on records if condition matches.
Comment 2 David Gustafsson 2019-05-31 10:56:20 UTC
Regarding the bug causing the tests to fail it was just a mismatch of my current schema version and code base, so forget about that part :)
Comment 3 David Gustafsson 2022-04-08 13:05:18 UTC
Created attachment 133121 [details] [review]
Bug 23009: Add -set_deleted_marc_conditions to export_records

Add -set_deleted_marc_conditions argument to export_records script
for setting deleted flag on records if condition matches.

To test:

1) Run tests in t/db_dependent/Exporter/Record.t

Sponsored-by: Gothenburg University Library
Comment 4 David Gustafsson 2022-04-08 13:13:33 UTC
Rebased. Also renamed option to something more descriptive, the previous was pretty awful as you would probably expect the conditions be applied the same way as for normal records but for deleted ones. -set_deleted_marc_conditions will set the deleted flag for matching records, and are not conditions applied to filter records out as the previous parameter name implied.
Comment 5 David Gustafsson 2025-02-05 18:13:56 UTC
Created attachment 177550 [details] [review]
Bug 23009: Add -set_deleted_marc_conditions to export_records

Add -set_deleted_marc_conditions argument to export_records script
for setting deleted flag on records if condition matches.

To test:

1) Run tests in t/db_dependent/Exporter/Record.t

Sponsored-by: Gothenburg University Library
Comment 6 David Gustafsson 2025-02-05 18:14:44 UTC
Rebased against master.