aboutsummaryrefslogtreecommitdiffstats
path: root/install
diff options
context:
space:
mode:
Diffstat (limited to 'install')
-rw-r--r--install/database.sql4
-rw-r--r--install/update.php12
2 files changed, 14 insertions, 2 deletions
diff --git a/install/database.sql b/install/database.sql
index addf797a7..c8b9d4867 100644
--- a/install/database.sql
+++ b/install/database.sql
@@ -223,6 +223,7 @@ CREATE TABLE IF NOT EXISTS `event` (
`aid` int(10) unsigned NOT NULL DEFAULT '0',
`uid` int(11) NOT NULL,
`event_xchan` char(255) NOT NULL DEFAULT '',
+ `event_hash` char(255) NOT NULL DEFAULT '',
`message_id` char(255) NOT NULL,
`created` datetime NOT NULL,
`edited` datetime NOT NULL,
@@ -249,7 +250,8 @@ CREATE TABLE IF NOT EXISTS `event` (
KEY `adjust` (`adjust`),
KEY `nofinish` (`nofinish`),
KEY `ignore` (`ignore`),
- KEY `aid` (`aid`)
+ KEY `aid` (`aid`),
+ KEY `event_hash` (`event_hash`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
CREATE TABLE IF NOT EXISTS `fcontact` (
diff --git a/install/update.php b/install/update.php
index 63d65c89c..5479f1e26 100644
--- a/install/update.php
+++ b/install/update.php
@@ -1,6 +1,6 @@
<?php
-define( 'UPDATE_VERSION' , 1018 );
+define( 'UPDATE_VERSION' , 1019 );
/**
*
@@ -269,3 +269,13 @@ function update_r1017() {
return UPDATE_SUCCESS;
return UPDATE_FAILED;
}
+
+function update_r1018() {
+ $r = q("ALTER TABLE `event` ADD `event_hash` CHAR( 255 ) NOT NULL DEFAULT '' AFTER `event_xchan` ,
+ADD INDEX ( `event_hash` )");
+ if($r)
+ return UPDATE_SUCCESS;
+ return UPDATE_FAILED;
+}
+
+