When I upload a video, the file is uploaded, but the nid field is empty in the table and the vid is wrong, it should be 1787, this is a record from the video_files table.

| vid | fid  | nid | dimensions | status | started | completed  | data 
|  65 | 1635 |   0 | 640x480    |      1 |       0 |          0 | NULL  

When running drush video-scheduler the video is converted, and the record is updated.

| vid | fid  | nid | dimensions | status | started | completed  | data 
|  65 | 1635 |   0 | 640x480    |     10 |       0 | 1299715175 | a:2:{i:0;O:8:"stdClass":8:{s:3:"vid";s:2:"65";s:8:"filename";s:12:"mov006_0.flv";s:8:"filepath";s:49:"sites/default/files/videos/converted/mov006_0.flv";s:8:"filemime";s:11:"video/x-flv";s:8:"filesize";i:1605193;s:6:"status";i:10;s:6:"preset";s:8:"hq_flash";s:9:"completed";i:1299714876;}i:1;O:8:"stdClass":8:{s:3:"vid";s:2:"65";s:8:"filename";s:12:"mov006_0.mp4";s:8:"filepath";s:49:"sites/default/files/videos/converted/mov006_0.mp4";s:8:"filemime";s:9:"video/mp4";s:8:"filesize";i:3022195;s:6:"status";i:10;s:6:"preset";s:9:"html5_mp4";s:9:"completed";i:1299715175;}}

But, as you can see the nid is empty and the vid is still wrong.

This causes the video field not to load on node view. My guess is that this is a bug but I don't know. I ran update.php and everything seems to be ok, this is the table I have:

mysql> show columns from video_files;
+------------+------------------+------+-----+---------+----------------+
| Field      | Type             | Null | Key | Default | Extra          |
+------------+------------------+------+-----+---------+----------------+
| vid        | int(10) unsigned | NO   | PRI | NULL    | auto_increment | 
| fid        | int(10) unsigned | NO   | MUL | 0       |                | 
| nid        | int(10) unsigned | NO   |     | 0       |                | 
| dimensions | varchar(255)     | YES  |     |         |                | 
| status     | int(10) unsigned | NO   | MUL | 0       |                | 
| started    | int(11)          | NO   |     | 0       |                | 
| completed  | int(11)          | NO   |     | 0       |                | 
| data       | longtext         | YES  |     | NULL    |                | 
+------------+------------------+------+-----+---------+----------------+
8 rows in set (0.01 sec)

Comments

lelizondo’s picture

Title: Empty nid and wrong vid » NID is always 0
Category: support » bug

My mistake about vid, I see now it is video id so it can't be wrong, but the nid is still 0

hypertext200’s picture

What are your configurations?. I tested and its working fine in my local box.
For debug see the line : 143 in video.module

function video_form_alter(&$form, &$form_state, $form_id) {
if (isset($form['type']) && isset($form['#node']) && $form['type']['#value'] . '_node_form' == $form_id) {
$form['buttons']['submit']['#submit'][] = 'video_node_update_submit';
}
}
?>
There we actually updating the node id.
hypertext200’s picture

Category: bug » task
lelizondo’s picture

Here it is. I've been updating the module for quite a long time, could that be the problem?

Edit: I saw the line 143 in the video.module but it is a line inside a hook_theme(). Are you sure is the right line?

Jorrit’s picture

Category: task » bug
Status: Active » Postponed (maintainer needs more info)

Is this problem still present?

Jorrit’s picture

Status: Postponed (maintainer needs more info) » Closed (works as designed)

Closed because of lack of response.