You are here

function video_zencoder_update_6401 in Video 6.5

Same name and namespace in other branches
  1. 6.4 plugins/video_zencoder/video_zencoder.install \video_zencoder_update_6401()

Implementation of hook_update_N().

Adding new dimensions column to the table

File

plugins/video_zencoder/video_zencoder.install, line 161
Provides installation functions for video_s3.module.

Code

function video_zencoder_update_6401() {
  $ret = array();

  // set settings column to accept larger values
  switch ($GLOBALS['db_type']) {
    case 'mysql':
    case 'mysqli':
      $ret[] = update_sql('ALTER TABLE {video_zencoder} ADD dimensions VARCHAR( 255 ) NULL NULL AFTER filesize');
      break;
    case 'pgsql':
      db_add_column($ret, 'video_zencoder', 'dimensions', 'VARCHAR', array(
        'null' => TRUE,
      ));
      break;
  }
  return $ret;
}