Bug 21951 - Patron import fails if matching on cardnumber and userid also matches
Summary: Patron import fails if matching on cardnumber and userid also matches
Status: RESOLVED DUPLICATE of bug 21465
Alias: None
Product: Koha
Classification: Unclassified
Component: Patrons (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal (vote)
Assignee: Kyle M Hall
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-12-05 12:36 UTC by Kyle M Hall
Modified: 2018-12-07 19:12 UTC (History)
4 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments
Bug 21951: Patron import fails if matching on cardnumber and userid also matches (1.62 KB, patch)
2018-12-05 13:49 UTC, Kyle M Hall
Details | Diff | Splinter Review
Bug 21951: Patron import fails if matching on cardnumber and userid also matches (1.65 KB, patch)
2018-12-05 14:35 UTC, Owen Leonard
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Kyle M Hall 2018-12-05 12:36:44 UTC
If a patron CSV file has both cardnumber and userid, and cardnumber is used as a matchpoint, the patron import will fail with an error like
--
Userid kyle.hall is already used by another patron.
--
even though that userid is used by the very same patron!

Matching on userid does not generate this error.
Comment 1 Kyle M Hall 2018-12-05 13:49:11 UTC
Created attachment 82860 [details] [review]
Bug 21951: Patron import fails if matching on cardnumber and userid also matches

If a patron CSV file has both cardnumber and userid, and cardnumber is used as a matchpoint, the patron import will fail with an error like
--
Userid kyle.hall is already used by another patron.
--
even though that userid is used by the very same patron!

Matching on userid does not generate this error.

Test Plan:
1) Generate a patron CSV file where the userid and cardnumber columns match an existing patron
2) Attempt to overlay existing patron using this CSV file via the patron import tool
3) Note the "already used" error
4) Apply this patch
5) No error should be generated
6) Modify the cardnumber in the CSV file
7) Attempt to import and overlay again
8) Note you get the userid "already used" error
Comment 2 Owen Leonard 2018-12-05 14:35:39 UTC
Created attachment 82869 [details] [review]
Bug 21951: Patron import fails if matching on cardnumber and userid also matches

If a patron CSV file has both cardnumber and userid, and cardnumber is
used as a matchpoint, the patron import will fail with an error like
--
Userid kyle.hall is already used by another patron.
--
even though that userid is used by the very same patron!

Matching on userid does not generate this error.

Test Plan:
1) Generate a patron CSV file where the userid and cardnumber columns
   match an existing patron
2) Attempt to overlay existing patron using this CSV file via the
   patron import tool
3) Note the "already used" error
4) Apply this patch
5) No error should be generated
6) Modify the cardnumber in the CSV file
7) Attempt to import and overlay again
8) Note you get the userid "already used" error

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Comment 3 Katrin Fischer 2018-12-06 08:49:19 UTC
Is this a duplicate of bug 21465?
Comment 4 Nick Clemens 2018-12-07 19:12:40 UTC

*** This bug has been marked as a duplicate of bug 21465 ***