Hi Nalisha, It sounds like you want to find items with identical barcodes (ignoring a leading zero), then delete their related biblios? If that's the case then this report should return the list of related biblios that you can then feed to Batch item/record deletion tools.
SELECT biblionumber FROM items i WHERE i.barcode IN (SELECT CONCAT('0', barcode) FROM items) To be perfectly clear, this returns the *biblionumber* for the associated bibliographic records for items with barcodes like "2412" where another item exists with barcode "02412". It would retain your manually created records. So if you were to feed this list of biblios to the batch record deletion tool <https://koha-community.org/manual/19.05/en/html/tools.html#batch-record-deletion-label> you would end up with no duplicates. I believe this also causes the orphaned item records to be removed as well. I tested it briefly on our system by creating a fake item with a duplicate barcode plus leading zero and it did retrieve the intended result. There was no screenshot attached to your email, FYI. Perhaps the mailing list didn't allow it. Best, ERIC PHETTEPLACE Systems Librarian (he/him) ephettepl...@cca.edu | o 510.594.3660 5212 Broadway | Oakland, CA | 94618 :(){ :|: & };: On Tue, Jan 21, 2020 at 11:29 AM Nalisha Tamang <n...@ptsindia.com> wrote: > Dear all, > As we have imported 26,ooo books into koha and I already had 4700 books > entered manually . as I have added 0 in front of barcode with the 4700 > books e.g (02412). when i imported 26000 books it didn't replace the > existing records which has no 0 in front of barcode e.g (2400). Now when I > check the catalog it shows many duplicates. which would be 26000 books + > 4700 books + duplicate biblios. Now I don't know what to do????????? > I have attached the screenshot... please help me ASAP.... > With regards, > Nalisha > _______________________________________________ > Koha mailing list http://koha-community.org > Koha@lists.katipo.co.nz > https://lists.katipo.co.nz/mailman/listinfo/koha > _______________________________________________ Koha mailing list http://koha-community.org Koha@lists.katipo.co.nz https://lists.katipo.co.nz/mailman/listinfo/koha