aboutsummaryrefslogtreecommitdiffstats
path: root/database.sql
diff options
context:
space:
mode:
Diffstat (limited to 'database.sql')
-rw-r--r--[-rwxr-xr-x]database.sql14
1 files changed, 8 insertions, 6 deletions
diff --git a/database.sql b/database.sql
index a271e5491..010c63bb2 100755..100644
--- a/database.sql
+++ b/database.sql
@@ -34,10 +34,11 @@ CREATE TABLE IF NOT EXISTS `challenge` (
CREATE TABLE IF NOT EXISTS `config` (
`id` int(10) unsigned NOT NULL AUTO_INCREMENT,
- `cat` char(255) NOT NULL,
- `k` char(255) NOT NULL,
+ `cat` char(255) CHARACTER SET ascii COLLATE ascii_general_ci NOT NULL,
+ `k` char(255) CHARACTER SET ascii COLLATE ascii_general_ci NOT NULL,
`v` text NOT NULL,
- PRIMARY KEY (`id`)
+ PRIMARY KEY (`id`),
+ UNIQUE KEY `access`(`cat`,`k`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
@@ -542,9 +543,10 @@ INDEX ( `batch` )
CREATE TABLE IF NOT EXISTS `pconfig` (
`id` INT NOT NULL AUTO_INCREMENT PRIMARY KEY ,
`uid` INT NOT NULL DEFAULT '0',
-`cat` CHAR( 255 ) NOT NULL ,
-`k` CHAR( 255 ) NOT NULL ,
-`v` MEDIUMTEXT NOT NULL
+`cat` CHAR( 255 ) CHARACTER SET ascii COLLATE ascii_general_ci NOT NULL ,
+`k` CHAR( 255 ) CHARACTER SET ascii COLLATE ascii_general_ci NOT NULL ,
+`v` MEDIUMTEXT NOT NULL,
+UNIQUE KEY `access`(`cat`, `k`)
) ENGINE = MyISAM DEFAULT CHARSET=utf8;