summaryrefslogtreecommitdiff
path: root/database
diff options
context:
space:
mode:
Diffstat (limited to 'database')
-rw-r--r--database/database.mysql4
-rw-r--r--database/database.pgsql2
-rw-r--r--database/updates.inc10
3 files changed, 12 insertions, 4 deletions
diff --git a/database/database.mysql b/database/database.mysql
index 7496db8f2..88126a0fb 100644
--- a/database/database.mysql
+++ b/database/database.mysql
@@ -151,7 +151,7 @@ CREATE TABLE boxes (
info varchar(128) NOT NULL default '',
type tinyint(2) NOT NULL default '0',
PRIMARY KEY (bid),
- UNIQUE KEY subject (title),
+ UNIQUE KEY title (title),
UNIQUE KEY info (info)
) TYPE=MyISAM;
@@ -363,7 +363,7 @@ CREATE TABLE profile_fields (
type varchar(128) default NULL,
weight tinyint(1) DEFAULT '0' NOT NULL,
required tinyint(1) DEFAULT '0' NOT NULL,
- overview tinyint(1) DEFAULT '0' NOT NULL,
+ visibility tinyint(1) DEFAULT '0' NOT NULL,
options text,
KEY category (category),
UNIQUE KEY name (name),
diff --git a/database/database.pgsql b/database/database.pgsql
index bb4ae1e3d..73c737a33 100644
--- a/database/database.pgsql
+++ b/database/database.pgsql
@@ -379,7 +379,7 @@ CREATE TABLE profile_fields (
type varchar(128) default NULL,
weight smallint DEFAULT '0' NOT NULL,
required smallint DEFAULT '0' NOT NULL,
- overview smallint DEFAULT '0' NOT NULL,
+ visibility smallint DEFAULT '0' NOT NULL,
options text,
UNIQUE (name),
PRIMARY KEY (fid)
diff --git a/database/updates.inc b/database/updates.inc
index ba66ff511..ef53af326 100644
--- a/database/updates.inc
+++ b/database/updates.inc
@@ -60,7 +60,8 @@ $sql_updates = array(
"2004-05-10" => "update_86",
"2004-05-18" => "update_87",
"2004-06-11" => "update_88",
- "2004-06-18" => "update_89"
+ "2004-06-18" => "update_89",
+ "2004-06-27" => "update_90"
);
function update_32() {
@@ -1120,6 +1121,13 @@ function update_89() {
return $ret;
}
+function update_90() {
+ $ret[] = update_sql("ALTER TABLE {profile_fields} CHANGE overview visibility INT(1) UNSIGNED DEFAULT '0' NOT NULL");
+ $ret[] = update_sql("UPDATE {profile_fields} SET visibility = 2 WHERE visibility = 1");
+ $ret[] = update_sql("UPDATE {profile_fields} SET visibility = 1 WHERE visibility = 0");
+ return $ret;
+}
+
function update_sql($sql) {
$edit = $_POST["edit"];
$result = db_query($sql);