Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
If field name length is higher than 24, it is impossible to add that field to view. Views does not show any error or warning message, just close the "Add field" window and does not add the field.
Is there any workaround to use fields with name length is higher than 24.
Thanks
Comments
Comment #1
dshields CreditAttribution: dshields at OpenConcept Consulting Inc. commentedI can't replicate that issue myself. I wonder if it's related to the version of jQuery you're running.
Maybe try turning off JavaScript for views here: admin/structure/views/settings/advanced
Comment #2
coolman7 CreditAttribution: coolman7 commentedI'm using jQuery update module 7.x-2.5 and jQuery v1.7.
First I disabled jQuery update module, nothing has changed.
Than I turned off Javascript at admin/structure/views/settings/advanced, nothing has changed.
I'm using ubuntu 14.04 as server and PHP 5.5. Could that be problem? I faced some problems with PHP 5.5 incompatibilities.
Comment #3
dshields CreditAttribution: dshields at OpenConcept Consulting Inc. commentedI really have no idea, but can confirm that it is not an issue with Views, from what I'm seeing.
Comment #4
coolman7 CreditAttribution: coolman7 commentedIs there any field name length limitation at views?
Comment #5
dshields CreditAttribution: dshields at OpenConcept Consulting Inc. commentedI'm afraid I don't have an answer to that, but in trying to help you test this, I was able to add a field with a 33-character machine name.
Comment #6
coolman7 CreditAttribution: coolman7 commentedI installed brand new apache2/php/mysql to my local ubuntu. And installed brand new drupal and views. I added same content type and same field with 27 letters long. It worked. So what could be the problem? How can I debug it?
Comment #7
Christopher Riley CreditAttribution: Christopher Riley commentedI ran into this same issue which had me totally baffled until I read this post. I then used drush to copy the field to a name with less characters and then used mysql to copy the contents. As so as that happened I could attach the field.
I went from:
field_featured_slideshow_image
to:
field_slideshow_image
Comment #8
coolman7 CreditAttribution: coolman7 commentedI found another workaround. I export view to text file and manually add field that has long name to text file. Than import view with new text.
Comment #9
drummWe ran into this on Drupal.org, the solution was upping https://suhosin.org/stories/configuration.html#suhosin-post-max-array-in... & https://suhosin.org/stories/configuration.html#suhosin-request-max-array...
Comment #10
MustangGB CreditAttribution: MustangGB commentedClosing this issue then, as it's not necessarily specific to views, possibly more related to system config, and workarounds have been found/used.