You are here

function system_update_6002 in Drupal 6

Increase the maximum length of variable names from 48 to 128.

Related topics

File

modules/system/system.install, line 1245

Code

function system_update_6002() {
  $ret = array();
  db_drop_primary_key($ret, 'variable');
  db_change_field($ret, 'variable', 'name', 'name', array(
    'type' => 'varchar',
    'length' => 128,
    'not null' => TRUE,
    'default' => '',
  ));
  db_add_primary_key($ret, 'variable', array(
    'name',
  ));
  return $ret;
}