<?php
/**
 * Phoebe pedagogic planner
 *
 * PHP version 5
 *
 * LICENSE: The GNU General Public License (GPL), version 2. See LICENSE.txt
 *
 * Copyright (c) 2006-2008 JISC/HEFCE/University of Oxford
 *
 * @author      David Balch <david.balch@conted.ox.ac.uk>
 * @license     http://opensource.org/licenses/gpl-license.php GPL2
 * @link        http://phoebe-project.conted.ox.ac.uk/
 */


/* Save the value for a property */
include_once($_SERVER['DOCUMENT_ROOT'].'/inc/core.php');
include_once($_SERVER['DOCUMENT_ROOT'].'/inc/session.php');
include_once($_SERVER['DOCUMENT_ROOT'].'/inc/utils.php');

/*
$sql = 'CREATE TABLE settings '.
       '(language text(8), default_template_id integer)';

$sql = 'ALTER TABLE users '.
       'ADD user_created timestamp';

$sql = 'ALTER TABLE users '.
       'ADD confirmation_code text(128)';
       
$sql = 'ALTER TABLE designs '.
       'ADD is_template boolean';

$sql = 'ALTER TABLE users '.
       'ADD pref_default_template_id integer';

$sql = 'ALTER TABLE users '.
       'DROP created';

$sql = 'UPDATE properties '.
       "SET multiplicity = 1 ".
       'WHERE prop_id = 31981';

$sql = 'UPDATE designs '.
       'SET share_level = 0 '.
       'WHERE design_id = 1';

$sql = 'UPDATE users '.
       "SET pref_default_template_id = null ".
       'WHERE user_id = 20';

$sql = 'UPDATE refs '.
       "SET uri = 'http://phoebe-guidance.conted.ox.ac.uk/cgi-bin/trac.cgi/wiki/PhoebeApproachIntroduction'".
       'WHERE ref_id = 6499';

$sql = 'DELETE FROM users '.
       "WHERE user_id = '27'";
*/

//$sql = 'DROP TABLE settings';

echo $sql;

//$update = $mdb2->exec($sql);
if (PEAR::isError($update)) {
    echo 'Error: '.$update->getMessage();
    echo "\nSQL: ".$sql;
} else {
    echo $value;
}
?>