Uploaded image for project: 'mod-source-record-storage'
  1. mod-source-record-storage
  2. MODSOURCE-531

Can't update "MARC" record, which was created by stopped import job

    XMLWordPrintable

Details

    • 3
    • Folijet Support
    • Morning Glory R2 2022 Bug Fix
    • Legitimate regression

    Description

      Overview: if import of "MARC" records was stopped by user, the created records impossible to update via "Data import" app because it leads to error.
      Steps to Reproduce: (steps describe the issue on example of "MARC Authority" record)

      1. Log into Snapshot FOLIO environment as User with the following permissions:
        Data import: Can upload files, import, and view logs
        Settings (Data import): Can view, create, edit, and remove
        Edit MARC authority record
        View MARC authority record
        quickMARC: View, edit MARC authorities record
        Inventory: All permissions
        quickMARC: View, edit MARC bibliographic record
        UI: Data export module is enabled
      2. Navigate to the "Data import" app.
      3. Trigger the data import by clicking on the "or choose file" button at jobs panel and submitting the attached "100_MARC_authority_records.mrc" file.
      4. When the job appears on the "Jobs" panel, click on the delete icon.
      5. Once import stops and the new record appears with "Stopped by user" status, click on the title at the appeared row and note any name of "MARC Authority" record with created status at the "Authority" column.
      6. Navigate to the "MARC Authority" app and find the record that you noted at step 5.
      7. Check the checkbox next to this record.
      8. Click on the "Actions" button and select the "Export selected records (CSV/MARC)" option.
      9. Navigate to "Data export" app and download generated ".mrc" file by clicking on title at the appeared row.
      10. Open downloaded ".mrc" file via "MarcEditor".
      11. Edit any value of 1XX-998 fields in opened "MARC Authority" record.
      12. Save ".mrc" file with changes made.
      13. Navigate to "Settings/Data import/Match profiles"
         13.1. Create a new matching profile:
                Existing records = MARC Authority
                Incoming record type = MARC Authority
                Incoming MARC Authority record:
                Field = 999, Ind 1 = f, Ind 2 = f, Subfield = s
                Don't check "Use qualifier" and "Only compare part of this value"
                Match criterion = Exactly matches
                Existing MARC Authority record:
                Field = 999, Ind 1 = f, Ind 2 = f, Subfield = s
                Don't check "Use qualifier" and "Only compare part of this value"
         >>Save the match profile.
        13.2. Go to Field mapping profiles and create a new one:
                 Incoming record type = MARC Authority
                  FOLIO record type = MARC Authority
                  Field mappings for MARC = Updates
          >>Click on the "Save as profile and close" button.

                 13.3. Go to Action profiles and create a new action profile:
                          Action = Update (all record types except Orders)
                          FOLIO record type = MARC Authority
                          Link the mapping profile to this action profile.
                   >>Click on the "Save as profile and close" button.

                  13.4. Go to Job profiles and create a new job profile:
                          Accepted data type = MARC
                          Click on "+" button and select "Match" option
                          Choose the match profile created earlier
                          In "For matches" tab: Click on "+" button and select "Action" option
                          Choose the action profile created earlier
                    >>Click on the "Save as profile and close" button.

             14. Navigate to "Data import" app and trigger the data import by clicking on the "or choose file" button at jobs panel and submitting ".mrc" file with updated "MARC Authority" record (from step 12).
             15. Select update job profile that you created at step 13 (e.g.: "Update MARC authority records by matching 999 ff $s subfield value")
             16. Click on the "Actions menu" button > Select "Run" > Click on the "Run" button at displayed modal.

      Expected Results: Once import is complete, then a new row with "Completed" status will display at log details.
      Actual Results: Once import is complete, then a new row with "Completed with errors" status is displayed in log details. The error message: "io.vertx.pgclient.PgException: ERROR: duplicate key value violates unique constraint "idx_records_matched_id_gen" (23505)" displaying when user click on the name of imported record.
      Additional Information: See attached screencasts.
      if import of "MARC Authority" / "MARC Bibliographic" records was stopped by user, the created records impossible to update via "Data import" app because it leads to error: "io.vertx.pgclient.PgException: ERROR: duplicate key value violates unique constraint "idx_records_matched_id_gen" (23505)".
      You can reproduce the same issue for "MARC Bibliographic" record by using the attached file: "UChicagoCatA_Bibs.mrc"
      Interested parties:  kgambrell  and abreaux 

      TestRail: Results

        Attachments

          Issue Links

            Activity

              People

                VRohach Volodymyr Rohach
                valpil Valery Pilko
                Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                  Created:
                  Updated:

                  TestRail: Runs

                    TestRail: Cases