· 4 years ago · Jan 22, 2021, 08:42 AM
1-- MySQL dump 10.13 Distrib 8.0.22, for Win64 (x86_64)
2--
3-- Host: localhost Database: db_remedioscaseros
4-- ------------------------------------------------------
5-- Server version 8.0.22
6
7/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
8/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
9/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
10/*!50503 SET NAMES utf8 */;
11/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
12/*!40103 SET TIME_ZONE='+00:00' */;
13/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
14/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
15/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
16/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
17
18--
19-- Table structure for table `ingredientes`
20--
21
22DROP TABLE IF EXISTS `ingredientes`;
23/*!40101 SET @saved_cs_client = @@character_set_client */;
24/*!50503 SET character_set_client = utf8mb4 */;
25CREATE TABLE `ingredientes` (
26 `id` int NOT NULL AUTO_INCREMENT,
27 `nombreingrediente` varchar(45) NOT NULL,
28 PRIMARY KEY (`id`)
29) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
30/*!40101 SET character_set_client = @saved_cs_client */;
31
32--
33-- Dumping data for table `ingredientes`
34--
35
36LOCK TABLES `ingredientes` WRITE;
37/*!40000 ALTER TABLE `ingredientes` DISABLE KEYS */;
38INSERT INTO `ingredientes` VALUES (1,'Banana'),(2,'Limon'),(3,'Manzana'),(4,'Pera'),(5,'Naranja');
39/*!40000 ALTER TABLE `ingredientes` ENABLE KEYS */;
40UNLOCK TABLES;
41
42--
43-- Table structure for table `receta`
44--
45
46DROP TABLE IF EXISTS `receta`;
47/*!40101 SET @saved_cs_client = @@character_set_client */;
48/*!50503 SET character_set_client = utf8mb4 */;
49CREATE TABLE `receta` (
50 `id` int NOT NULL AUTO_INCREMENT,
51 `FK_remedio` int NOT NULL,
52 `FK_ingrediente` int NOT NULL,
53 `cantidad` int NOT NULL,
54 PRIMARY KEY (`id`),
55 KEY `FK_remedio_idx` (`FK_remedio`),
56 KEY `FK_ingrediente_idx` (`FK_ingrediente`),
57 CONSTRAINT `FK_ingrediente` FOREIGN KEY (`FK_ingrediente`) REFERENCES `ingredientes` (`id`),
58 CONSTRAINT `FK_remedio` FOREIGN KEY (`FK_remedio`) REFERENCES `remedios` (`id`)
59) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
60/*!40101 SET character_set_client = @saved_cs_client */;
61
62--
63-- Dumping data for table `receta`
64--
65
66LOCK TABLES `receta` WRITE;
67/*!40000 ALTER TABLE `receta` DISABLE KEYS */;
68INSERT INTO `receta` VALUES (1,1,3,4),(2,2,4,8),(3,3,2,7),(4,4,1,9),(5,5,3,10);
69/*!40000 ALTER TABLE `receta` ENABLE KEYS */;
70UNLOCK TABLES;
71
72--
73-- Table structure for table `remedios`
74--
75
76DROP TABLE IF EXISTS `remedios`;
77/*!40101 SET @saved_cs_client = @@character_set_client */;
78/*!50503 SET character_set_client = utf8mb4 */;
79CREATE TABLE `remedios` (
80 `id` int NOT NULL AUTO_INCREMENT,
81 `nombreremedio` varchar(45) NOT NULL,
82 PRIMARY KEY (`id`)
83) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
84/*!40101 SET character_set_client = @saved_cs_client */;
85
86--
87-- Dumping data for table `remedios`
88--
89
90LOCK TABLES `remedios` WRITE;
91/*!40000 ALTER TABLE `remedios` DISABLE KEYS */;
92INSERT INTO `remedios` VALUES (1,'Godzilla'),(2,'King Kong'),(3,'Nessie'),(4,'UltraMan'),(5,'Steven Seagal');
93/*!40000 ALTER TABLE `remedios` ENABLE KEYS */;
94UNLOCK TABLES;
95/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
96
97/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
98/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
99/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
100/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
101/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
102/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
103/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
104
105-- Dump completed on 2021-01-22 9:35:17
106