[Archivesspace_Users_Group] Issues with MySQL v8

Majewski, Steven Dennis (sdm7g) sdm7g at virginia.edu
Wed Mar 31 16:55:47 EDT 2021


I’m running ArchivesSpace 2.8.1 under current MariaDB 10.5.9 and I’m not getting any errors on any of those reports. 
It’s our intention to support current versions of both MySQL and MariaDB, but not everything can be tested against every version, especially those reports. 

Wendy: are you getting the same error message reported in that JIRA issue? 
> https://archivesspace.atlassian.net/jira/software/c/projects/ANW/issues/ANW-1200 <https://archivesspace.atlassian.net/jira/software/c/projects/ANW/issues/ANW-1200> 

Wendy and/or Blake: 
(I have a hunch) Can you try editing:
	archivesspace/reports/accessions/accession_names_subreport/accession_names_subreport.rb
And in the line: role_id as function,  quote the word function:

12c12
<       role_id as function,
---
>       role_id as 'function',


class AccessionNamesSubreport < AbstractSubreport

  def initialize(parent_report, accession_id)
    super(parent_report)
    @accession_id = accession_id
  end

  def query_string
    "select
      ifnull(ifnull(ifnull(name_person.sort_name, name_family.sort_name),
        name_corporate_entity.sort_name), 'Unknown') as name,
      role_id as function,
      relator_id as role
    from linked_agents_rlshp
      left outer join name_person
        on name_person.agent_person_id = linked_agents_rlshp.agent_person_id
      left outer join name_family
        on name_family.agent_family_id = linked_agents_rlshp.agent_family_id
      left outer join name_corporate_entity
        on name_corporate_entity.agent_corporate_entity_id = 
        linked_agents_rlshp.agent_corporate_entity_id
    where accession_id = #{db.literal(@accession_id)}"
  end

  def fix_row(row)
    ReportUtils.get_enum_values(row, [:function, :role])
  end

end


Or else replace it with this edited version:




And then restart ArchivesSpace and try Accession reports again? 



Actually, more than a hunch now that I googled for this doc:

https://dev.mysql.com/doc/refman/8.0/en/keywords.html#keywords-8-0-detailed-F <https://dev.mysql.com/doc/refman/8.0/en/keywords.html#keywords-8-0-detailed-F>

And see: 

FUNCTION (R); became reserved in 8.0.1


Pretty sure that is the problem!


— Steve Majewski



> On Mar 31, 2021, at 2:49 PM, Wendy Scheir <scheirw at newschool.edu> wrote:
> 
> Hi Blake,
> 
> Thanks so much for following up. So far, we've gotten report errors for the following 3 accessions reports:
> Accession Report
> Accession Receipt Report
> Accessions and Linked Subjects, Names and Classifications
> 
> I'm not sure if we've tested all of them, but definitely these 3 are erroring out. If you'd like to look at the error logs, I'd be glad to send them to you.
> 
> All best,
> Wendy
> ____________________________________
> WENDY SCHEIR
> DIRECTOR
> 
> 66 5TH AVENUE, NEW YORK, NY 10011
> scheirw at newschool.edu <mailto:scheirw at newschool.edu>
> T 212.229.5942 x2888
> Explore the Archives <http://library.newschool.edu/archives> | Digital Collections from the Archives <http://digitalarchives.library.newschool.edu/> | New School Histories <http://newschoolhistories.org/> | @tnsarchives <https://twitter.com/tnsarchives>
> 
> 
> On Wed, Mar 31, 2021 at 2:33 PM Blake Carver <blake.carver at lyrasis.org <mailto:blake.carver at lyrasis.org>> wrote:
> There are others running on 8, so far the only trouble seems to be reports. Here's a JIRA
> https://archivesspace.atlassian.net/jira/software/c/projects/ANW/issues/ANW-1200 <https://archivesspace.atlassian.net/jira/software/c/projects/ANW/issues/ANW-1200>
> You're seeing it fail on two reports?
> 
>  
> 
> From: archivesspace_users_group-bounces at lyralists.lyrasis.org <mailto:archivesspace_users_group-bounces at lyralists.lyrasis.org> <archivesspace_users_group-bounces at lyralists.lyrasis.org <mailto:archivesspace_users_group-bounces at lyralists.lyrasis.org>> on behalf of Wendy Scheir <scheirw at newschool.edu <mailto:scheirw at newschool.edu>>
> Sent: Tuesday, March 30, 2021 4:15 PM
> To: Archivesspace Users Group <archivesspace_users_group at lyralists.lyrasis.org <mailto:archivesspace_users_group at lyralists.lyrasis.org>>
> Subject: [Archivesspace_Users_Group] Issues with MySQL v8
>  
> Hi,
> 
> When we installed ArchivesSpace last summer, we used MySQL v8 for our database. The documentation has instructions that read, "if using for MySQL 8+..." leading us to believe that MySQL 8 was a supported version. However, we've been having issues running Accession and Shelflist reports that the Lyrasis team has told us is caused by running MySQL 8 instead of MySQL 5. In the interim, Lyrasis has updated the documentation to say that "ArchivesSpace is currently able to run on MySQL version 5.x."
> 
> Has anyone else installed ArchivesSpace with MySQL 8? We are concerned about downgrading to 5 versus waiting for a future version that works with 8, but in the meantime we are unable to run a number of desired reports.
> 
> Many thanks,
> Wendy
> ____________________________________
> WENDY SCHEIR
> DIRECTOR
> 
> 66 5TH AVENUE, NEW YORK, NY 10011
> scheirw at newschool.edu <mailto:scheirw at newschool.edu>
> T 212.229.5942 x2888
> Explore the Archives <http://library.newschool.edu/archives> | Digital Collections from the Archives <http://digitalarchives.library.newschool.edu/> | New School Histories <http://newschoolhistories.org/> | @tnsarchives <https://twitter.com/tnsarchives>
> _______________________________________________
> Archivesspace_Users_Group mailing list
> Archivesspace_Users_Group at lyralists.lyrasis.org <mailto:Archivesspace_Users_Group at lyralists.lyrasis.org>
> http://lyralists.lyrasis.org/mailman/listinfo/archivesspace_users_group <http://lyralists.lyrasis.org/mailman/listinfo/archivesspace_users_group>
> _______________________________________________
> Archivesspace_Users_Group mailing list
> Archivesspace_Users_Group at lyralists.lyrasis.org
> http://lyralists.lyrasis.org/mailman/listinfo/archivesspace_users_group

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lyralists.lyrasis.org/pipermail/archivesspace_users_group/attachments/20210331/83daca1a/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: accession_names_subreport.rb
Type: text/x-ruby-script
Size: 943 bytes
Desc: not available
URL: <http://lyralists.lyrasis.org/pipermail/archivesspace_users_group/attachments/20210331/83daca1a/attachment.bin>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lyralists.lyrasis.org/pipermail/archivesspace_users_group/attachments/20210331/83daca1a/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 3342 bytes
Desc: not available
URL: <http://lyralists.lyrasis.org/pipermail/archivesspace_users_group/attachments/20210331/83daca1a/attachment-0001.bin>


More information about the Archivesspace_Users_Group mailing list