Single Value (1) Image field importing as Multiple Values in Feeds

Created on 26 June 2020, about 5 years ago
Updated 7 April 2025, 3 months ago

I've created a CSV feed via Views Export that exports out data for a content type. I'm then using Feeds to import that onto another Drupal site.

Everything except the images are working, when I run import it's stating

Failed importing 2 RSS Item items.

The content failed to validate with the following errors:
Image (field_image): Image: this field cannot hold more than 1 values.
Please check your mappings.

The field in question on Site A has a single limited value of 1, and checking the CSV export it's only showing one value, the absolute url of the image on Site A.

I've attempted to use Feeds Tamper and use all the plugins I can think of to fix this, but due to my freshness to Feeds and Feeds Tamper I'm not sure if this is a bug or misconfig on my part. Everything else is importing as expected onto Site B.

🐛 Bug report
Status

Fixed

Version

3.0

Component

Code

Created by

🇬🇧United Kingdom Robhern135

Live updates comments and jobs are added and updated live.
  • Needs tests

    The change is currently missing an automated test that fails when run with the original code, and succeeds when the bug has been fixed.

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.

  • 🇩🇪Germany kopfduenger Wiesbaden

    Hi @MegaChriz,

    unfortunately, this issue for single value fields is still not resolved, at least for date fields. My content type is translatable, even the date field (although this does not make sense for a date field in my opinion).

    While importing the tag
    ... into a date field, the import fails due to:

    Veröffentlicht am (field_date): Veröffentlicht am: this field cannot hold more than 1 values.
    Please check your mappings.

  • 🇩🇪Germany kopfduenger Wiesbaden

    Hi @MegaChriz,

    sorry, my fault: I could solve my issue above with:
    - install module feed_ex
    - changing the XPath statement for this field in feeds_tamper
    and
    - installing the patch in this comment: https://www.drupal.org/project/feeds/issues/3172709#comment-14999631 🐛 Error "this field cannot hold more than 1 values" when manually filling parsed source fields via FeedsSubscriber RTBC

    In order to make it work, I had to use these settings:

    context: /rss/channel/item
    XPath value: pubDate
    both option fields checked for this 'custom source':
    - raw value
    - inner xml.

Production build 0.71.5 2024