From 10334d2b79f90a04e06df813eab4afe0ec714def Mon Sep 17 00:00:00 2001 From: hecht Date: Wed, 26 Oct 2011 20:23:06 +0000 Subject: [PATCH] adjusted the tables to fit the acutal version --- db/animegame_svn.sql | 41 +++++++++++++++++++++-------------------- 1 file changed, 21 insertions(+), 20 deletions(-) diff --git a/db/animegame_svn.sql b/db/animegame_svn.sql index 0444e0e..ff26e82 100644 --- a/db/animegame_svn.sql +++ b/db/animegame_svn.sql @@ -14,13 +14,6 @@ /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; --- --- Create schema test_ag --- - -CREATE DATABASE IF NOT EXISTS test_ag; -USE test_ag; - -- -- Definition of table `ag_chat` -- @@ -81,6 +74,14 @@ CREATE TABLE `arena` ( +DROP TABLE IF EXISTS `attack_conditions`; +CREATE TABLE `attack_conditions` ( + `id` int(11) NOT NULL AUTO_INCREMENT, + `name` varchar(20) COLLATE utf8_unicode_ci NOT NULL, + `formula` varchar(255) COLLATE utf8_unicode_ci NOT NULL, + PRIMARY KEY (`id`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; + -- -- Definition of table `attacken` -- @@ -118,14 +119,14 @@ CREATE TABLE `attacken` ( DROP TABLE IF EXISTS `attackenset`; CREATE TABLE `attackenset` ( - `Char_ID` int(11) NOT NULL, - `Attack_ID` int(11) NOT NULL, - `Type` int(11) NOT NULL DEFAULT '1', - `Round` int(2) NOT NULL, - PRIMARY KEY (`Char_ID`,`Type`,`Round`), - KEY `attackenset_attack_id` (`Attack_ID`), - CONSTRAINT `attackenset_attack_id` FOREIGN KEY (`Attack_ID`) REFERENCES `lernen` (`id`) ON DELETE CASCADE ON UPDATE CASCADE, - CONSTRAINT `attackenset_char_id` FOREIGN KEY (`Char_ID`) REFERENCES `chars` (`id`) ON DELETE CASCADE ON UPDATE CASCADE + `char_id` int(11) NOT NULL, + `attack_id` int(11) NOT NULL, + `type` int(11) NOT NULL DEFAULT '1', + `round` int(2) NOT NULL, + PRIMARY KEY (`char_ID`,`type`,`round`), + KEY `attackenset_attack_id` (`attack_id`), + CONSTRAINT `attackenset_attack_id` FOREIGN KEY (`attack_id`) REFERENCES `lernen` (`id`) ON DELETE CASCADE ON UPDATE CASCADE, + CONSTRAINT `attackenset_char_id` FOREIGN KEY (`char_id`) REFERENCES `chars` (`id`) ON DELETE CASCADE ON UPDATE CASCADE ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- @@ -1226,7 +1227,7 @@ CREATE TABLE `shop` ( `id` int(11) NOT NULL AUTO_INCREMENT, `com` varchar(50) COLLATE utf8_unicode_ci NOT NULL DEFAULT 'Kein Kommentar', PRIMARY KEY (`id`) USING BTREE -) ENGINE=MyISAM AUTO_INCREMENT=82 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Definition of table `sp_item` @@ -1244,7 +1245,7 @@ CREATE TABLE `sp_item` ( `tausch_lvl` int(2) NOT NULL DEFAULT '1', `tausch_anzahl` int(4) NOT NULL DEFAULT '1', PRIMARY KEY (`id`) -) ENGINE=InnoDB AUTO_INCREMENT=34 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Definition of table `sp_ware` @@ -1645,7 +1646,7 @@ CREATE TABLE `user_gruppe` ( `gruppen_beschreibung` text, PRIMARY KEY (`gruppen_id`), UNIQUE KEY `name` (`gruppen_name`) -) ENGINE=MyISAM AUTO_INCREMENT=11 DEFAULT CHARSET=latin1; +) ENGINE=InnoDB DEFAULT CHARSET=utf8; @@ -1659,7 +1660,7 @@ CREATE TABLE `user_gruppe_zuordnung` ( `gruppen_id` int(11) NOT NULL DEFAULT '0', UNIQUE KEY `user_id` (`user_id`,`gruppen_id`), KEY `fk_gruppe_user_gruppe` (`gruppen_id`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1; +) ENGINE=InnoDB DEFAULT CHARSET=utf8; -- -- Definition of table `user_rename` @@ -1823,7 +1824,7 @@ CREATE TABLE `wochen_markt` ( `tausch_anzahl` int(4) NOT NULL DEFAULT '1', PRIMARY KEY (`id`), UNIQUE KEY `item` (`item`) -) ENGINE=InnoDB AUTO_INCREMENT=43 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; --