Error when string too long for acronym

Created on 17 October 2019, over 4 years ago
Updated 9 February 2022, over 2 years ago

When importing a pubmed id list or xml record, I sometimes get the following error, when the content of the tag (in the XML version) is longer than 2 characters:
PDOException: SQLSTATE[22001]: String data, right truncated: 1406 Data too long for column 'acronym' at row 1: INSERT INTO {biblio_pubmed_grant_info} (nid, biblio_pubmed_id, grantid, acronym, agency, country) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2, :db_insert_placeholder_3, :db_insert_placeholder_4, :db_insert_placeholder_5); Array ( [:db_insert_placeholder_0] => 6044 [:db_insert_placeholder_1] => 31452289 [:db_insert_placeholder_2] => [:db_insert_placeholder_3] => ALZS_ [:db_insert_placeholder_4] => Alzheimer's Society [:db_insert_placeholder_5] => United Kingdom ) in drupal_write_record() (line 7401 of /home/dougla55/public_html/includes/common.inc).

You can see this in this citation:
https://www.ncbi.nlm.nih.gov/pubmed/31452289?report=xml&format=text
If you try to import this with the pubmed id or xml file, it throws an error. I did not have this issue before- I think it appeared with a recent update.

πŸ› Bug report
Status

Needs review

Version

1.0

Component

Code

Created by

πŸ‡¨πŸ‡¦Canada Sm1l3

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.69.0 2024