Bug 7132

Summary: Check for duplicates when creating a new record in acquisitions
Product: Koha Reporter: Nicole C. Engard <nengard>
Component: AcquisitionsAssignee: Laura Escamilla <Laura.escamilla>
Status: Passed QA --- QA Contact: Julian Maurice <julian.maurice>
Severity: enhancement    
Priority: P5 - low CC: ahennig, angela.berrett, esther.melander, julian.maurice, kgnerre, Laura.escamilla, lucas, michaela.sieber, mspinney, sbrown
Version: Main   
Hardware: All   
OS: All   
See Also: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35886
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15248
GIT URL: Change sponsored?: ---
Patch complexity: --- Documentation contact:
Documentation submission: Text to go in the release notes:
Acquisitions: duplicate check when ordering from an empty record When creating a new order via Acquisitions → New order (empty record), Koha now checks for existing bibliographic duplicates (using C4::Search::FindDuplicate). If a potential match is found, staff see the standard Duplicate warning screen with options to Use existing record, Create new anyway, or Cancel and return to the basket. This aligns the empty-record workflow with the existing duplicate checks used for external source imports and cataloging, reducing accidental duplicate bibs in the catalog.
Version(s) released in:
Circulation function:
Attachments: Bug 7132: Acq: Check for duplicates when ordering from empty record
Bug 7132: Acq: Check for duplicates when ordering from empty record
Bug 7132: Acq: Check for duplicates when ordering from empty record

Description Nicole C. Engard 2011-11-01 19:57:42 UTC
When you are in acquisitions if you order from an external source it checks for duplicates. If you order by entering a new empty record though it doesn't check for duplicates.  It should check for duplicates no matter how you're ordering (new record, z target, staged file, suggestion)
Comment 1 Sara Brown 2024-04-11 20:11:42 UTC
This is still an issue as of 23.05. A fix would save lots of de-duplication time for libraries who manually enter orders into acquisitions.
Comment 2 Kim Gnerre 2024-04-12 12:42:41 UTC
We have a newish Acquisitions person who has been ordering during the several month duration of no cataloger.  We just hired the cataloger and she's going through the new books waiting to be cataloged.  We had several duplicates and because it's been awhile, returning them will be a challenge.  I was under the impression that the acquisition module would catch duplicates at the point of entering them into a basket but it seems to not be the case.  We would really like this fixed.  It makes economical sense for libraries to prevent duplication and since that happens in other areas of Koha, to makes sense to translate it to this application.
Comment 3 Esther Melander 2025-05-16 17:01:39 UTC
Steps to replicate with a new file:

1. Add orders to a basket from a new file containing records that are not in the catalog.
2. Add orders to a basket again using the same import file. Be sure to set the import profile to check for matching records, replace, add incoming record if no match.
3. Notice the duplicate checking is ignored and duplicate bibs are now in the basket.

Ideally, when adding orders by importing a file the system should abide by the import profile instructions and the duplicate warning should appear just like with the z39.50 option. Instead it appears Koha is ignoring the import profile instructions and just adding the duplicates.
Comment 4 Laura Escamilla 2025-09-29 16:44:16 UTC
Created attachment 187062 [details] [review]
Bug 7132: Acq: Check for duplicates when ordering from empty record

To test using a new empty record:

1. Ensure you have a vendor and a new basket available for ordering. Click on “+Add to basket” and select “From a new (empty) record”
2. Choose an existing record to test with for example “CSS : the definitive guide” (http://localhost:8081/cgi-bin/koha/catalogue/detail.pl?biblionumber=12&searchid=scs_1759160315801)
3. Copy over the main details from the existing record in order to fill out the required details of the new order. I.e Title, and Koha item type. Click add item and then select a fund. It’s not necessary to fill anything else out.
4. Click save and notice that the duplicate record is not found.
5. Apply the patch and restart_all. Clear cache in your browser if necessary.
6. Repeat steps 2 - 4. This time a duplicate warning will appear. Ensure that all options of the duplicate warning work as expected.
7. Sign off and have a great day!
Comment 5 Andrew Fuerste-Henry 2025-09-30 13:40:04 UTC
Created attachment 187103 [details] [review]
Bug 7132: Acq: Check for duplicates when ordering from empty record

To test using a new empty record:

1. Ensure you have a vendor and a new basket available for ordering. Click on “+Add to basket” and select “From a new (empty) record”
2. Choose an existing record to test with for example “CSS : the definitive guide” (http://localhost:8081/cgi-bin/koha/catalogue/detail.pl?biblionumber=12&searchid=scs_1759160315801)
3. Copy over the main details from the existing record in order to fill out the required details of the new order. I.e Title, and Koha item type. Click add item and then select a fund. It’s not necessary to fill anything else out.
4. Click save and notice that the duplicate record is not found.
5. Apply the patch and restart_all. Clear cache in your browser if necessary.
6. Repeat steps 2 - 4. This time a duplicate warning will appear. Ensure that all options of the duplicate warning work as expected.
7. Sign off and have a great day!

Signed-off-by: Kim Gnerre <kgnerre@hotchkiss.org>
Comment 6 Julian Maurice 2025-10-02 12:34:54 UTC
Created attachment 187267 [details] [review]
Bug 7132: Acq: Check for duplicates when ordering from empty record

To test using a new empty record:

1. Ensure you have a vendor and a new basket available for ordering.
   Click on “+Add to basket” and select “From a new (empty) record”
2. Choose an existing record to test with for example “CSS : the
   definitive guide”
   (http://localhost:8081/cgi-bin/koha/catalogue/detail.pl?biblionumber=12&searchid=scs_1759160315801)
3. Copy over the main details from the existing record in order to fill
   out the required details of the new order. I.e Title, and Koha item
   type. Click add item and then select a fund. It’s not necessary to
   fill anything else out.
4. Click save and notice that the duplicate record is not found.
5. Apply the patch and restart_all. Clear cache in your browser if
   necessary.
6. Repeat steps 2 - 4. This time a duplicate warning will appear. Ensure
   that all options of the duplicate warning work as expected.
7. Sign off and have a great day!

Signed-off-by: Kim Gnerre <kgnerre@hotchkiss.org>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Comment 7 Julian Maurice 2025-10-02 12:36:40 UTC
Works as expected and QA script reports no error => Passed QA