From 15fe37a76b5c2ecda669e16a03f644ed14b9d0a3 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Sun, 27 Jun 2010 16:51:38 +0000 Subject: - Patch #838528 by marcingy: primary index on session table is not update when upgrading. --- includes/update.inc | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'includes') diff --git a/includes/update.inc b/includes/update.inc index b27dbff5a..7db61191e 100644 --- a/includes/update.inc +++ b/includes/update.inc @@ -586,6 +586,10 @@ function update_fix_d7_requirements() { // Add ssid column and index. db_add_field('sessions', 'ssid', array('description' => "Secure session ID. The value is generated by PHP's Session API.", 'type' => 'varchar', 'length' => 128, 'not null' => TRUE, 'default' => '')); db_add_index('sessions', 'ssid', array('ssid')); + // Drop existing primary key. + db_drop_primary_key('sessions'); + // Add new primary key. + db_add_primary_key('sessions', array('sid', 'ssid')); variable_set('update_d7_requirements', TRUE); } -- cgit v1.2.3