Changeset 709

Show
Ignore:
Timestamp:
09/03/05 12:43:21 (8 years ago)
Author:
aprilp
Message:

Added last_paged to table 'nodes'

Location:
trunk/wifidog-auth
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • trunk/wifidog-auth/ChangeLog

    r708 r709  
     12005-09-03 Philippe April  <philippe@ilesansfil.org> 
     2        * Schema change: Added last_paged column to nodes table 
     3 
    142005-09-01 Benoit Grégoire  <bock@step.polymtl.ca> 
    25        WARNING:  DO NOT use the CVS auth server in production until further notice.   
  • trunk/wifidog-auth/wifidog/include/schema_validate.php

    r708 r709  
    2828require_once BASEPATH.'classes/AbstractDb.php'; 
    2929require_once BASEPATH.'classes/Session.php'; 
    30 define('REQUIRED_SCHEMA_VERSION', 26); 
     30define('REQUIRED_SCHEMA_VERSION', 27); 
    3131 
    3232/** Check that the database schema is up to date.  If it isn't, offer to update it. */ 
     
    597597                        $sql .= ");\n"; 
    598598                } 
     599 
     600                $new_schema_version = 27; 
     601                if ($schema_version < $new_schema_version) 
     602                { 
     603                        echo "<h2>Preparing SQL statements to update schema to version  $new_schema_version</h2>\n"; 
     604                        $sql .= "\n\nUPDATE schema_info SET value='$new_schema_version' WHERE tag='schema_version';\n"; 
     605            $sql .= "ALTER TABLE nodes ADD COLUMN last_paged timestamp;\n"; 
     606 
     607                } 
     608 
    599609                $db->ExecSqlUpdate("BEGIN;\n$sql\nCOMMIT;\n", true); 
    600610                //$db->ExecSqlUpdate("BEGIN;\n$sql\nROLLBACK;\n", true);