[Archivesspace_Users_Group] Fwd: merge value error

brian brianjhoffman at gmail.com
Wed Jun 10 13:29:37 EDT 2015


Yes, i think that's right. There's a terms hash column on the subjects table so perhaps you could just search for dupes in that column and then review them.


Sent from my T-Mobile 4G LTE Device

<div>-------- Original message --------</div><div>From: "Callahan, Maureen" <maureen.callahan at yale.edu> </div><div>Date:06/10/2015  1:00 PM  (GMT-05:00) </div><div>To: Archivesspace Users Group <archivesspace_users_group at lyralists.lyrasis.org> </div><div>Cc:  </div><div>Subject: [Archivesspace_Users_Group] Fwd:  merge value error </div><div>
</div>ARGH — I’m realizing that it’s actually even more complicated than this, because if I were to just update the source IDs on the subjects table, I would get duplicate subject records. So really what I need to do is start by getting a list of subjects that are duplicated in all ways except for their source ids, determine which are the subject records with bad source ids, update the relationships table so that records are related to subjects with the good source information, THEN I can do the merges I want. But then, also, I have a bunch of orphan subjects that are unassociated with any records. James from HM wrote a handy script for us that zaps orphan subject records, so I suppose I could run that.

Maureen

Begin forwarded message:

From: "Callahan, Maureen" <maureen.callahan at yale.edu>
Subject: Re: [Archivesspace_Users_Group] merge value error
Date: June 10, 2015 at 11:27:33 AM EDT
To: Archivesspace Users Group <archivesspace_users_group at lyralists.lyrasis.org>

Hey Brian,

Oh, that makes sense. Could you help me think through what I need to do here? I basically want to start by getting a list of identifiers for enumeration values that I’m trying to merge into a given value — say, all of the values that should become “aat”. Then, I identify all records in the subjects table with non-legit source ids. Then, I do an update in the subjects table where I update the bad source ids (identified in the previous step) with the one that I want. Once that’s done, I should be able to merge the source values from the interface.

Is there an easier/safer way of doing this?

Thanks,
Maureen

On Jun 5, 2015, at 9:35 AM, Brian Hoffman <brianjhoffman at gmail.com> wrote:

Hi Maureen,

It kind of looks to me like you might have the following situation:

Two subject records with identical terms but different “source” values. The controlled values you are trying to merge would result in those two subject records having identical “source” values, and as a result be identical, which violates a uniqueness constraint in the database. Does that seem possible? If so, could you find those subject records first and de-dupe them?

Brian




On Jun 5, 2015, at 8:46 AM, Callahan, Maureen <maureen.callahan at yale.edu> wrote:

<mergeenums.txt>

_______________________________________________
Archivesspace_Users_Group mailing list
Archivesspace_Users_Group at lyralists.lyrasis.org
https://urldefense.proofpoint.com/v2/url?u=http-3A__lyralists.lyrasis.org_mailman_listinfo_archivesspace-5Fusers-5Fgroup&d=AwIF-g&c=-dg2m7zWuuDZ0MUcV7Sdqw&r=JgH2YCQ8D3P9-Lm_x4bv3d2CZBYlbx6hxnLFHtfovi8&m=dV_f9dLVb2pHqBsLSvZeWxpMEI58bKX9XCUnViWF3fk&s=mh0bb7LGZEk0NfeTHYSLy6KGsnRi847Ov_p21GRSkxc&e= 


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lyralists.lyrasis.org/pipermail/archivesspace_users_group/attachments/20150610/91c6a99c/attachment.html>


More information about the Archivesspace_Users_Group mailing list