2018-06-11 17:44:54 +02:00
|
|
|
CREATE TABLE `kd42696_ipr-projekt`.`entries` (
|
2018-06-11 17:56:22 +02:00
|
|
|
`id` INT NOT NULL AUTO_INCREMENT ,
|
2018-06-11 17:44:54 +02:00
|
|
|
`userID` INT NOT NULL ,
|
|
|
|
`tanID` INT NOT NULL ,
|
|
|
|
`vorname` LONGTEXT NOT NULL ,
|
|
|
|
`nachname` LONGTEXT NOT NULL ,
|
|
|
|
`geburtstag` LONGTEXT NOT NULL ,
|
|
|
|
`wohnort` LONGTEXT NOT NULL ,
|
|
|
|
`strasse` LONGTEXT NOT NULL ,
|
|
|
|
`kennenUns` LONGTEXT NOT NULL ,
|
|
|
|
`festnetz` LONGTEXT NOT NULL ,
|
|
|
|
`handynummer` LONGTEXT NOT NULL ,
|
|
|
|
`email` LONGTEXT NOT NULL ,
|
|
|
|
`hobbies` LONGTEXT NOT NULL ,
|
|
|
|
`berufswunsch` LONGTEXT NOT NULL ,
|
|
|
|
`essen` LONGTEXT NOT NULL ,
|
|
|
|
`insel` LONGTEXT NOT NULL ,
|
|
|
|
`film` LONGTEXT NOT NULL ,
|
|
|
|
`sport` LONGTEXT NOT NULL ,
|
|
|
|
`charakter` LONGTEXT NOT NULL ,
|
|
|
|
`tier` LONGTEXT NOT NULL ,
|
|
|
|
`musik` LONGTEXT NOT NULL ,
|
|
|
|
`game` LONGTEXT NOT NULL ,
|
|
|
|
`alk` LONGTEXT NOT NULL ,
|
|
|
|
`story` LONGTEXT NOT NULL ,
|
|
|
|
`absturz` LONGTEXT NOT NULL ,
|
|
|
|
`trinkspiel` LONGTEXT NOT NULL ,
|
2018-06-11 17:56:22 +02:00
|
|
|
PRIMARY KEY (`id`),
|
2018-06-11 17:44:54 +02:00
|
|
|
UNIQUE (`userID`),
|
|
|
|
UNIQUE (`tanID`)) ENGINE = InnoDB;
|
|
|
|
|
|
|
|
ALTER TABLE `entries` ADD FOREIGN KEY (`userID`) REFERENCES `user`(`ID`) ON DELETE CASCADE ON UPDATE CASCADE;
|
|
|
|
ALTER TABLE `entries` ADD FOREIGN KEY (`tanID`) REFERENCES `tans`(`id`) ON DELETE CASCADE ON UPDATE CASCADE;
|