From f7f316cd01dd307015bf3a9fd78b77d9ab097bf5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=A1bor=20Hojtsy?= Date: Sat, 1 Sep 2007 07:11:00 +0000 Subject: #165957 by hswong3i: create the variables table early, to make some DB driver writing a happier process --- modules/system/system.schema | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) (limited to 'modules/system/system.schema') diff --git a/modules/system/system.schema b/modules/system/system.schema index 2e63b39ff..a3ee189b0 100644 --- a/modules/system/system.schema +++ b/modules/system/system.schema @@ -2,6 +2,17 @@ // $Id$ function system_schema() { + // NOTE: {variable} needs to be created before all other tables, as + // some database drivers, e.g. Oracle and DB2, will require variable_get() + // and variable_set() for overcoming some database specific limitations. + $schema['variable'] = array( + 'fields' => array( + 'name' => array('type' => 'varchar', 'length' => 128, 'not null' => TRUE, 'default' => ''), + 'value' => array('type' => 'text', 'not null' => TRUE, 'size' => 'big'), + ), + 'primary key' => array('name'), + ); + $schema['actions'] = array( 'fields' => array( 'aid' => array('type' => 'varchar', 'length' => 255, 'not null' => TRUE, 'default' => '0'), @@ -205,13 +216,5 @@ function system_schema() { 'indexes' => array('src' => array('src')), ); - $schema['variable'] = array( - 'fields' => array( - 'name' => array('type' => 'varchar', 'length' => 128, 'not null' => TRUE, 'default' => ''), - 'value' => array('type' => 'text', 'not null' => TRUE, 'size' => 'big'), - ), - 'primary key' => array('name'), - ); - return $schema; } -- cgit v1.2.3