Download & Extend

emfield does not work well after updating from drupal 5 to 6

Project:Embedded Media Field
Version:6.x-1.15
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:active

Issue Summary

here is the error shown after clicking Save.

user warning: Column 'field_video_value' cannot be null query: INSERT INTO content_type_blog (vid, nid, field_video_embed, field_video_value, field_video_provider, field_video_data, field_video_version, field_video_duration) VALUES (131, 131, NULL, NULL, NULL, 'N;', 0, 0) in /Users/xx/Sites/drupal/sites/all/modules/cck/content.module on line 1213.

I updated from drupal 5 to 6 and ran all updates.

any ideas how to fix this?

Thanks.

Comments

#1

Title:Error when posting node with no video attached» emfield does not work well after updating from drupal 5 to 6

ok, did some more testing and I was able to fix using phpmyadmin.

WORK AROUND FIX
looking at table content_type_blog structure (or whatever content_type you have the video field added to)
2 fields not set correctly.
field_video_value NULL set to NO
field_video_provider NULL set to NO

i changed from NOT NULL to NULL to fix it.

seems several things are not getting updated when switching from drupal 5.x to 6.x
after updating and still having the errors i ran update and forced emfield and emvideo and some ran and some failed, but did not fix these errors.

so I am changing the title.

#2

I have the same error and I do not understand your solution. If the field video_value NULL is set to no.... what then do you change from NOT NULL to NULL?

I add here that the Schema module also reports:

  * column field_embvideo_value - differences on: not null, default
      declared: array('description' => t('TODO: please describe this field!'), 'type' => 'varchar', 'length' => 255, 'not null' => FALSE)
      actual: array('description' => t('TODO: please describe this field!'), 'type' => 'varchar', 'length' => '255', 'not null' => TRUE, 'default' => '')
    * column field_embvideo_provider - differences on: not null, default
      declared: array('description' => t('TODO: please describe this field!'), 'type' => 'varchar', 'length' => 255, 'not null' => FALSE)
      actual: array('description' => t('TODO: please describe this field!'), 'type' => 'varchar', 'length' => '255', 'not null' => TRUE, 'default' => '')

If only I knew what to do now.

#3

Just upgraded to Emfield 6.x-2.1 but the error messages keep popping up on my sites:

user warning: Column 'field_video_value' cannot be null query: INSERT INTO KLIMA_content_field_video (vid, nid, field_video_embed, field_video_value, field_video_provider, field_video_data, field_video_status, field_video_version, field_video_duration) VALUES (1143, 1142, NULL, NULL, NULL, 'a:1:{s:7:\"emthumb\";a:0:{}}', 1, 0, 0) in /home/klimatos/public_html/sites/all/modules/cck/content.module on line 1277.

#4

This was solved by deleting these two fields in the table specifying the involved content type.

nobody click here