You are here

function system_update_133 in Drupal 5

Same name and namespace in other branches
  1. 4 database/updates.inc \system_update_133()

File

modules/system/system.install, line 1614

Code

function system_update_133() {
  $ret = array();
  if ($GLOBALS['db_type'] == 'mysql') {
    $ret[] = update_sql("CREATE TABLE {contact} (\n      subject varchar(255) NOT NULL default '',\n      recipients longtext NOT NULL,\n      reply longtext NOT NULL\n      )");
    $ret[] = update_sql("ALTER TABLE {users} ADD login int NOT NULL default '0'");
  }
  elseif ($GLOBALS['db_type'] == 'pgsql') {

    // Table {contact} is changed in update_143() so I have moved it's creation there.
    // It was never created here for postgres because of errors.
    db_add_column($ret, 'users', 'login', 'int', array(
      'default' => 0,
      'not null' => TRUE,
    ));
  }
  return $ret;
}