SHARE
TWEET

Olympics DB dump

a guest Aug 2nd, 2012 12 Never
  1. -- phpMyAdmin SQL Dump
  2. -- version 2.11.6
  3. -- http://www.phpmyadmin.net
  4. --
  5. -- Serveur: localhost
  6. -- Généré le : Jeu 02 Août 2012 à 15:47
  7. -- Version du serveur: 5.0.51
  8. -- Version de PHP: 5.2.6
  9.  
  10. SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
  11.  
  12. --
  13. -- Base de données: `olympics`
  14. --
  15.  
  16. -- --------------------------------------------------------
  17.  
  18. --
  19. -- Structure de la table `game`
  20. --
  21.  
  22. CREATE TABLE `game` (
  23.   `id` tinyint(3) UNSIGNED NOT NULL AUTO_INCREMENT,
  24.   `playerA_id` tinyint(3) UNSIGNED NOT NULL,
  25.   `playerB_id` tinyint(3) UNSIGNED NOT NULL,
  26.   PRIMARY KEY  (`id`),
  27.   UNIQUE KEY `playerA_id` (`playerA_id`,`playerB_id`)
  28. ) ENGINE=InnoDB  DEFAULT CHARSET=utf8;
  29.  
  30. --
  31. -- Contenu de la table `game`
  32. --
  33.  
  34. INSERT INTO `game` (`id`, `playerA_id`, `playerB_id`) VALUES
  35. (1, 1, 4),
  36. (2, 1, 5),
  37. (3, 2, 4),
  38. (4, 2, 5),
  39. (5, 3, 5);
  40.  
  41. -- --------------------------------------------------------
  42.  
  43. --
  44. -- Structure de la table `player`
  45. --
  46.  
  47. CREATE TABLE `player` (
  48.   `id` tinyint(3) UNSIGNED NOT NULL AUTO_INCREMENT,
  49.   `team_id` tinyint(3) UNSIGNED NOT NULL,
  50.   `name` VARCHAR(50) NOT NULL,
  51.   PRIMARY KEY  (`id`),
  52.   KEY `team_id` (`team_id`)
  53. ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 ;
  54.  
  55. --
  56. -- Contenu de la table `player`
  57. --
  58.  
  59. INSERT INTO `player` (`id`, `team_id`, `name`) VALUES
  60. (1, 1, 'Laurent Dupuis'),
  61. (2, 1, 'Stéphane Leroy'),
  62. (3, 1, 'Julien le Guen'),
  63. (4, 2, 'Mark Johnsson'),
  64. (5, 2, 'John McGrath'),
  65. (6, 2, 'Alec Russell');
  66.  
  67. -- --------------------------------------------------------
  68.  
  69. --
  70. -- Structure de la table `team`
  71. --
  72.  
  73. CREATE TABLE `team` (
  74.   `id` tinyint(3) UNSIGNED NOT NULL AUTO_INCREMENT,
  75.   `country` VARCHAR(50) NOT NULL,
  76.   PRIMARY KEY  (`id`)
  77. ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 ;
  78.  
  79. --
  80. -- Contenu de la table `team`
  81. --
  82.  
  83. INSERT INTO `team` (`id`, `country`) VALUES
  84. (1, 'France'),
  85. (2, 'The United Kingdom');
RAW Paste Data
Top