Créé dans le cadre du projet de fin d'année de la promo 2018 de CIR2 de l'ISEN Brest/Rennes, le Burger Quizz est une adaptation numérique du jeu télévisé éponyme, plus précisément d'une épreuve spécifique de ce jeu : le "Sel ou Poivre".

burgerquizzSTRUCT.sql 3.0KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116
  1. -- phpMyAdmin SQL Dump
  2. -- version 4.2.12deb2
  3. -- http://www.phpmyadmin.net
  4. --
  5. -- Client : localhost
  6. -- Généré le : Sam 23 Mai 2015 à 15:14
  7. -- Version du serveur : 5.5.43-0+deb8u1
  8. -- Version de PHP : 5.6.7-1
  9. SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
  10. SET time_zone = "+00:00";
  11. /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
  12. /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
  13. /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
  14. /*!40101 SET NAMES utf8 */;
  15. --
  16. -- Base de données : `burgerquizz`
  17. --
  18. -- --------------------------------------------------------
  19. --
  20. -- Structure de la table `categorie`
  21. --
  22. CREATE TABLE IF NOT EXISTS `categorie` (
  23. `nom_cat` varchar(30) NOT NULL
  24. ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
  25. -- --------------------------------------------------------
  26. --
  27. -- Structure de la table `questions`
  28. --
  29. CREATE TABLE IF NOT EXISTS `questions` (
  30. `intitule` varchar(150) NOT NULL,
  31. `num_reponse` tinyint(4) NOT NULL,
  32. `reponse1` varchar(50) NOT NULL DEFAULT '',
  33. `reponse2` varchar(50) NOT NULL DEFAULT ''
  34. ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
  35. -- --------------------------------------------------------
  36. --
  37. -- Structure de la table `reponses`
  38. --
  39. CREATE TABLE IF NOT EXISTS `reponses` (
  40. `reponse1` varchar(50) NOT NULL,
  41. `reponse2` varchar(50) NOT NULL,
  42. `nom_cat` varchar(30) NOT NULL
  43. ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
  44. -- --------------------------------------------------------
  45. --
  46. -- Structure de la table `scores`
  47. --
  48. CREATE TABLE IF NOT EXISTS `scores` (
  49. `login` varchar(20) NOT NULL,
  50. `score` int(11) NOT NULL
  51. ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
  52. --
  53. -- Index pour les tables exportées
  54. --
  55. --
  56. -- Index pour la table `categorie`
  57. --
  58. ALTER TABLE `categorie`
  59. ADD PRIMARY KEY (`nom_cat`);
  60. --
  61. -- Index pour la table `questions`
  62. --
  63. ALTER TABLE `questions`
  64. ADD PRIMARY KEY (`intitule`,`reponse1`,`reponse2`), ADD KEY `FK_Questions_reponse2` (`reponse2`), ADD KEY `FK_Questions_reponse1` (`reponse1`);
  65. --
  66. -- Index pour la table `reponses`
  67. --
  68. ALTER TABLE `reponses`
  69. ADD PRIMARY KEY (`reponse1`,`reponse2`), ADD KEY `reponse2` (`reponse2`), ADD KEY `FK_Reponses_nom_cat` (`nom_cat`);
  70. --
  71. -- Index pour la table `scores`
  72. --
  73. ALTER TABLE `scores`
  74. ADD PRIMARY KEY (`login`);
  75. --
  76. -- Contraintes pour les tables exportées
  77. --
  78. --
  79. -- Contraintes pour la table `questions`
  80. --
  81. ALTER TABLE `questions`
  82. ADD CONSTRAINT `FK_Questions_reponse1` FOREIGN KEY (`reponse1`) REFERENCES `reponses` (`reponse1`) ON DELETE CASCADE ON UPDATE CASCADE,
  83. ADD CONSTRAINT `FK_Questions_reponse2` FOREIGN KEY (`reponse2`) REFERENCES `reponses` (`reponse2`) ON DELETE CASCADE ON UPDATE CASCADE;
  84. --
  85. -- Contraintes pour la table `reponses`
  86. --
  87. ALTER TABLE `reponses`
  88. ADD CONSTRAINT `FK_Reponses_nom_cat` FOREIGN KEY (`nom_cat`) REFERENCES `categorie` (`nom_cat`) ON DELETE CASCADE ON UPDATE CASCADE;
  89. /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
  90. /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
  91. /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;