[Bug 25657] New: Import Patron fails without userid - not stated as required field in notes
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25657 Bug ID: 25657 Summary: Import Patron fails without userid - not stated as required field in notes Change sponsored?: --- Product: Koha Version: 19.11 Hardware: All OS: All Status: NEW Severity: normal Priority: P5 - low Component: Patrons Assignee: koha-bugs@lists.koha-community.org Reporter: eb@efdss.org QA Contact: testopia@bugs.koha-community.org CC: gmcharlt@gmail.com, kyle.m.hall@gmail.com Somewhere in a recent upgrade, the userid became a required field for importing patrons. If it is not present Koha will attempt to use the userid from the person logged in for all userids. This causes the import to fail as they're 'duplicate'. This is an easy fix - update the notes to state the userid is a required field. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25657 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jonathan.druart@bugs.koha-c | |ommunity.org --- Comment #1 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Hi Elaine, I have tried on 19.11.06, I am not sure I understand what the problem is. If I use the import patron tool to create new patrons and the csv file does not contain a userid (either no value in the cell, or no header at all), then the userid is automatically built concatenating firstname and surname. Can you detail a bit more? -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25657 Elaine Bradtke <eb@efdss.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |eb@efdss.org --- Comment #2 from Elaine Bradtke <eb@efdss.org> --- This happened in 19.11.05. I upload and overwrite the patron data on a quarterly basis (it's derived from a spreadsheet of membership data). The error message I got was: "Userid elaine.bradtke is already used by another patron" repeated for all 2000+ records. I went back to the spreadsheet, gave everyone arbitrary userids and it worked. Just to test this wasn't a fluke, I've gone back to the spreadsheet, removed the userid column and tried the upload again. It failed: mport results : 0 imported records 0 overwritten 0 not imported because already in borrowers table and overwrite disabled 2124 not imported because they are not in the expected format 2124 records parsed Back to Tools Feedback: headerrow : cardnumber, title, firstname, surname, address, address2, city, state, zipcode, country, dateexpiry, email, phone, branchcode, categorycode, Content-Disposition : form-data; name="uploadborrowers"; filename="EFDSS - Membership Export 2020-06-02.csv" Content-Type : application/octet-stream Parsing upload file EFDSS - Membership Export 2020-06-02.csv Error analysis: Userid elaine.bradtke is already used by another patron. (repeated 2000+ times) -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25657 --- Comment #3 from Elaine Bradtke <eb@efdss.org> --- (In reply to Jonathan Druart from comment #1)
Hi Elaine,
I have tried on 19.11.06, I am not sure I understand what the problem is. If I use the import patron tool to create new patrons and the csv file does not contain a userid (either no value in the cell, or no header at all), then the userid is automatically built concatenating firstname and surname.
Can you detail a bit more?
Are you saying it would work if there was a column userid, but no data in it? We've never had a userid field empty or not, in previous imports and it worked. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25657 --- Comment #4 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Yes, I have tried with: * "userid" header and no data in it * no userid header In both cases the import succeeded, and the patrons had a userid=firstname.surname Could you create a new patron with a given userid, login with it, then use a simple version of the CSV file? If you can recreate the problem (on a sandbox for intance), share the CSV sample file and I will investigate what's going on. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25657 --- Comment #5 from Elaine Bradtke <eb@efdss.org> --- We have two instances of Koha, they are supposed to be identical (one test, one production) I always do large imports in test first. The problem seems to be in the test site, I just successfully imported into production the same patron data that failed in test. I'll have a word with our tech person as to what differences there are, aside from being on two different cloud servers. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25657 --- Comment #6 from Elaine Bradtke <eb@efdss.org> --- We're using two different versions of the OS - The production system where the import works: Linux library.efdss.org 3.16.0-4-amd64 #1 SMP Debian 3.16.51-2 (2017-12-03) x86_64 The test system - where the import fails is running: Linux public 4.9.0-12-amd64 #1 SMP Debian 4.9.210-1 (2020-01-20) x86_64 -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25657 --- Comment #7 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Hi Elaine, is userid listed in your BorrowerMandatoryFields system preference by chance? -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25657 --- Comment #8 from Elaine Bradtke <eb@efdss.org> --- (In reply to Katrin Fischer from comment #7)
Hi Elaine, is userid listed in your BorrowerMandatoryFields system preference by chance?
surname|cardnumber is all we have - in both production and test sites. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25657 Daniel Gaghan <daniel.gaghan@pueblolibrary.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |daniel.gaghan@pueblolibrary | |.org -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25657 --- Comment #9 from Daniel Gaghan <daniel.gaghan@pueblolibrary.org> --- We are seeing this issue too, borrowernumber wasn't required before 19.11 so this is a new bug. PCCLD is definitely in favor of not requiring borrowernumber in a patron import. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25657 --- Comment #10 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- (In reply to Daniel Gaghan from comment #9)
We are seeing this issue too, borrowernumber wasn't required before 19.11 so this is a new bug. PCCLD is definitely in favor of not requiring borrowernumber in a patron import.
Hi Daniel, I think it might be good to file a separate bug for the borrowernumber as this was about the userid and link them together. I agree the borrowernumber should not be mandatory. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25657 --- Comment #11 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- I have tested creating and overlaying patrons on master, with a file with 2 patrons and a header file of: cardnumber,surname,firstname,branchcode,categorycode All worked well. I think we need to narrow this down some more if it only appears in older versions, differences in the files etc. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25657 --- Comment #12 from Elaine Bradtke <eb@efdss.org> --- I've found the answer as to what is happening. It has to do with default values. We ignore this option when uploading patron records. However, the password auto-fill in Chrome doesn't. It filled in my staff-login information as a default entry. Then the import failed because this was duplicated for every record, and already in use. Since userid is supposed to be unique, I would argue that having this as a default value is a recipe for failure. Regardless of the auto-fill problem, if I were to enter a default value in this field, it wouldn't be unique. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25657 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Version|19.11 |master Summary|Import Patron fails without |Remove username from |userid - not stated as |default value form in |required field in notes |patron import --- Comment #13 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Hi Elaine, thx for not giving up investigating here. I agree that userid/username does not really make sense on this form. I have changed the bug description accordingly. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25657 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Remove username from |Remove username and |default value form in |cardnumber from default |patron import |value form in patron import -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org