Created
March 19, 2018 16:22
-
-
Save Jules59/1b57da450953628b3f564da11ff682c2 to your computer and use it in GitHub Desktop.
SQL part2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- MySQL dump 10.13 Distrib 5.7.21, for Linux (x86_64) | |
-- | |
-- Host: localhost Database: wcs | |
-- ------------------------------------------------------ | |
-- Server version 5.7.21-0ubuntu0.17.10.1 | |
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; | |
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; | |
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; | |
/*!40101 SET NAMES utf8 */; | |
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; | |
/*!40103 SET TIME_ZONE='+00:00' */; | |
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; | |
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; | |
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; | |
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */; | |
-- | |
-- Table structure for table `booking` | |
-- | |
DROP TABLE IF EXISTS `booking`; | |
/*!40101 SET @saved_cs_client = @@character_set_client */; | |
/*!40101 SET character_set_client = utf8 */; | |
CREATE TABLE `booking` ( | |
`ID` int(11) NOT NULL AUTO_INCREMENT, | |
`date` datetime DEFAULT NULL, | |
`duration` time DEFAULT NULL, | |
`user_ID` int(11) DEFAULT NULL, | |
`room_ID` int(11) DEFAULT NULL, | |
PRIMARY KEY (`ID`), | |
KEY `user_ID` (`user_ID`), | |
KEY `room_ID` (`room_ID`), | |
CONSTRAINT `booking_ibfk_1` FOREIGN KEY (`user_ID`) REFERENCES `user` (`ID`), | |
CONSTRAINT `booking_ibfk_2` FOREIGN KEY (`room_ID`) REFERENCES `room` (`ID`) | |
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=latin1; | |
/*!40101 SET character_set_client = @saved_cs_client */; | |
-- | |
-- Dumping data for table `booking` | |
-- | |
LOCK TABLES `booking` WRITE; | |
/*!40000 ALTER TABLE `booking` DISABLE KEYS */; | |
INSERT INTO `booking` VALUES (1,'2018-03-19 09:30:00','00:30:00',1,1),(2,'2018-03-19 10:00:00','00:30:00',2,1),(3,'2018-03-19 10:30:00','00:30:00',3,1),(4,'2018-03-19 09:30:00','00:30:00',4,5),(5,'2018-03-19 10:00:00','00:30:00',5,5),(6,'2018-03-19 09:30:00','00:30:00',6,3),(7,'2018-03-19 09:30:00','00:30:00',7,6),(8,'2018-03-19 10:00:00','00:30:00',8,6),(9,'2018-03-17 10:30:00','00:30:00',9,6),(10,'2018-03-17 11:00:00','00:30:00',10,6); | |
/*!40000 ALTER TABLE `booking` ENABLE KEYS */; | |
UNLOCK TABLES; | |
-- | |
-- Table structure for table `room` | |
-- | |
DROP TABLE IF EXISTS `room`; | |
/*!40101 SET @saved_cs_client = @@character_set_client */; | |
/*!40101 SET character_set_client = utf8 */; | |
CREATE TABLE `room` ( | |
`ID` int(11) NOT NULL AUTO_INCREMENT, | |
`name` varchar(80) DEFAULT NULL, | |
PRIMARY KEY (`ID`) | |
) ENGINE=InnoDB AUTO_INCREMENT=7 DEFAULT CHARSET=latin1; | |
/*!40101 SET character_set_client = @saved_cs_client */; | |
-- | |
-- Dumping data for table `room` | |
-- | |
LOCK TABLES `room` WRITE; | |
/*!40000 ALTER TABLE `room` DISABLE KEYS */; | |
INSERT INTO `room` VALUES (1,'Salle de dojo'),(2,'Salle de réunion'),(3,'Salle de repos'),(4,'Cuisine'),(5,'Bureau'),(6,'OpenSpace'); | |
/*!40000 ALTER TABLE `room` ENABLE KEYS */; | |
UNLOCK TABLES; | |
-- | |
-- Table structure for table `user` | |
-- | |
DROP TABLE IF EXISTS `user`; | |
/*!40101 SET @saved_cs_client = @@character_set_client */; | |
/*!40101 SET character_set_client = utf8 */; | |
CREATE TABLE `user` ( | |
`ID` int(11) NOT NULL AUTO_INCREMENT, | |
`lastname` varchar(80) DEFAULT NULL, | |
`firstname` varchar(80) DEFAULT NULL, | |
`home` varchar(80) DEFAULT NULL, | |
`role` varchar(16) DEFAULT NULL, | |
`language` varchar(16) DEFAULT NULL, | |
PRIMARY KEY (`ID`) | |
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=latin1; | |
/*!40101 SET character_set_client = @saved_cs_client */; | |
-- | |
-- Dumping data for table `user` | |
-- | |
LOCK TABLES `user` WRITE; | |
/*!40000 ALTER TABLE `user` DISABLE KEYS */; | |
INSERT INTO `user` VALUES (1,'lemaire','julien','lambersart','student','PHP'),(2,'claude','amandine','lambersart','student','PHP'),(3,'canis','julien','seclin','student','PHP'),(4,'bruge','louis','lille','student','PHP'),(5,'poirier','lucas','lille','student','JS'),(6,'goo','gle','californie','student','PHP'),(7,'pester','loire','paris','student','PHP'),(8,'master','yoda','dagobah','trainer','PHP'),(9,'dark','vador','deathstar','trainer','JS'),(10,'solo','han','corellia','trainer','PHP'); | |
/*!40000 ALTER TABLE `user` ENABLE KEYS */; | |
UNLOCK TABLES; | |
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */; | |
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */; | |
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */; | |
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */; | |
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; | |
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; | |
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; | |
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */; | |
-- Dump completed on 2018-03-19 17:21:24 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment