From d7e270db5936913daba202a5e1e2c1e9ea7db9ee Mon Sep 17 00:00:00 2001 From: Simon Rettberg Date: Thu, 21 May 2015 17:16:23 +0200 Subject: Support statictics slxlog messages (Starting with '.'), those go to a special table --- apis/update.inc.php | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'apis/update.inc.php') diff --git a/apis/update.inc.php b/apis/update.inc.php index ac680aef..4cf03b0e 100644 --- a/apis/update.inc.php +++ b/apis/update.inc.php @@ -223,3 +223,19 @@ function update_8() Database::exec("ALTER TABLE `configtgz` ADD `status` ENUM( 'OK', 'OUTDATED', 'MISSING' ) NOT NULL DEFAULT 'MISSING'"); return true; } + +function update_9() +{ + Database::exec("CREATE TABLE IF NOT EXISTS `statistic` ( + `logid` int(10) unsigned NOT NULL AUTO_INCREMENT, + `dateline` int(10) unsigned NOT NULL, + `typeid` varchar(30) NOT NULL, + `clientip` varchar(40) NOT NULL, + `username` varchar(30) NOT NULL, + `data` varchar(255) NOT NULL, + PRIMARY KEY (`logid`), + KEY `dateline` (`dateline`), + KEY `logtypeid` (`typeid`,`dateline`), + KEY `clientip` (`clientip`,`dateline`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8"); +} \ No newline at end of file -- cgit v1.2.3-55-g7522