· 6 years ago · Oct 29, 2019, 06:22 AM
1CREATE DATABASE IF NOT EXISTS `university_john` /*!40100 DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci */ /*!80016 DEFAULT ENCRYPTION='N' */;
2USE `university_john`;
3-- MySQL dump 10.13 Distrib 8.0.18, for Win64 (x86_64)
4--
5-- Host: localhost Database: university
6-- ------------------------------------------------------
7-- Server version 8.0.18
8
9/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
10/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
11/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
12/*!50503 SET NAMES utf8 */;
13/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
14/*!40103 SET TIME_ZONE='+00:00' */;
15/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
16/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
17/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
18/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
19
20--
21-- Table structure for table `course`
22--
23
24DROP TABLE IF EXISTS `course`;
25/*!40101 SET @saved_cs_client = @@character_set_client */;
26/*!50503 SET character_set_client = utf8mb4 */;
27CREATE TABLE `course` (
28 `IDCourse` int(11) NOT NULL,
29 `IDSpec` int(11) DEFAULT NULL,
30 `Name` varchar(50) DEFAULT NULL,
31 `TeachingYear` year(4) DEFAULT NULL,
32 `Semester` tinyint(4) DEFAULT NULL,
33 `Professor` varchar(50) DEFAULT NULL,
34 `Credits` tinyint(4) DEFAULT NULL,
35 PRIMARY KEY (`IDCourse`)
36) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
37/*!40101 SET character_set_client = @saved_cs_client */;
38
39--
40-- Dumping data for table `course`
41--
42
43LOCK TABLES `course` WRITE;
44/*!40000 ALTER TABLE `course` DISABLE KEYS */;
45/*!40000 ALTER TABLE `course` ENABLE KEYS */;
46UNLOCK TABLES;
47
48--
49-- Table structure for table `faculty`
50--
51
52DROP TABLE IF EXISTS `faculty`;
53/*!40101 SET @saved_cs_client = @@character_set_client */;
54/*!50503 SET character_set_client = utf8mb4 */;
55CREATE TABLE `faculty` (
56 `IDFac` int(11) DEFAULT NULL,
57 `Name` varchar(50) DEFAULT NULL,
58 `Adress` varchar(200) DEFAULT NULL,
59 `YearFounded` year(4) DEFAULT NULL,
60 `Dean` varchar(50) DEFAULT NULL
61) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
62/*!40101 SET character_set_client = @saved_cs_client */;
63
64--
65-- Dumping data for table `faculty`
66--
67
68LOCK TABLES `faculty` WRITE;
69/*!40000 ALTER TABLE `faculty` DISABLE KEYS */;
70/*!40000 ALTER TABLE `faculty` ENABLE KEYS */;
71UNLOCK TABLES;
72
73--
74-- Table structure for table `grade`
75--
76
77DROP TABLE IF EXISTS `grade`;
78/*!40101 SET @saved_cs_client = @@character_set_client */;
79/*!50503 SET character_set_client = utf8mb4 */;
80CREATE TABLE `grade` (
81 `IDGrade` int(11) NOT NULL,
82 `IDStud` int(11) DEFAULT NULL,
83 `IDCourse` int(11) DEFAULT NULL,
84 `Name` varchar(50) DEFAULT NULL,
85 `Grade` int(11) DEFAULT NULL,
86 `ExamDate` date DEFAULT NULL,
87 PRIMARY KEY (`IDGrade`)
88) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
89/*!40101 SET character_set_client = @saved_cs_client */;
90
91--
92-- Dumping data for table `grade`
93--
94
95LOCK TABLES `grade` WRITE;
96/*!40000 ALTER TABLE `grade` DISABLE KEYS */;
97/*!40000 ALTER TABLE `grade` ENABLE KEYS */;
98UNLOCK TABLES;
99
100--
101-- Table structure for table `speciality`
102--
103
104DROP TABLE IF EXISTS `speciality`;
105/*!40101 SET @saved_cs_client = @@character_set_client */;
106/*!50503 SET character_set_client = utf8mb4 */;
107CREATE TABLE `speciality` (
108 `IDSpec` int(11) NOT NULL,
109 `IDFac` int(11) DEFAULT NULL,
110 `Name` varchar(50) DEFAULT NULL,
111 PRIMARY KEY (`IDSpec`)
112) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
113/*!40101 SET character_set_client = @saved_cs_client */;
114
115--
116-- Dumping data for table `speciality`
117--
118
119LOCK TABLES `speciality` WRITE;
120/*!40000 ALTER TABLE `speciality` DISABLE KEYS */;
121/*!40000 ALTER TABLE `speciality` ENABLE KEYS */;
122UNLOCK TABLES;
123
124--
125-- Table structure for table `studdata`
126--
127
128DROP TABLE IF EXISTS `studdata`;
129/*!40101 SET @saved_cs_client = @@character_set_client */;
130/*!50503 SET character_set_client = utf8mb4 */;
131CREATE TABLE `studdata` (
132 `IDStud` int(11) NOT NULL,
133 `CNP` varchar(13) DEFAULT NULL,
134 `FirstName` varchar(50) DEFAULT NULL,
135 `LastName` varchar(50) DEFAULT NULL,
136 `Father` varchar(50) DEFAULT NULL,
137 `Mother` varchar(50) DEFAULT NULL,
138 `Adress` varchar(200) DEFAULT NULL,
139 `Nationality` varchar(50) DEFAULT NULL,
140 PRIMARY KEY (`IDStud`)
141) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
142/*!40101 SET character_set_client = @saved_cs_client */;
143
144--
145-- Dumping data for table `studdata`
146--
147
148LOCK TABLES `studdata` WRITE;
149/*!40000 ALTER TABLE `studdata` DISABLE KEYS */;
150/*!40000 ALTER TABLE `studdata` ENABLE KEYS */;
151UNLOCK TABLES;
152
153--
154-- Table structure for table `student`
155--
156
157DROP TABLE IF EXISTS `student`;
158/*!40101 SET @saved_cs_client = @@character_set_client */;
159/*!50503 SET character_set_client = utf8mb4 */;
160CREATE TABLE `student` (
161 `IDStud` int(11) DEFAULT NULL,
162 `IDFac` int(11) DEFAULT NULL,
163 `IDSpec` int(11) DEFAULT NULL,
164 `Name` varchar(50) DEFAULT NULL,
165 `CurrentYear` year(4) DEFAULT NULL,
166 `StudyGroup` varchar(10) DEFAULT NULL,
167 `Semester` tinyint(4) DEFAULT NULL,
168 `Scholarship` varchar(3) DEFAULT NULL
169) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
170/*!40101 SET character_set_client = @saved_cs_client */;
171
172--
173-- Dumping data for table `student`
174--
175
176LOCK TABLES `student` WRITE;
177/*!40000 ALTER TABLE `student` DISABLE KEYS */;
178/*!40000 ALTER TABLE `student` ENABLE KEYS */;
179UNLOCK TABLES;
180/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
181
182/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
183/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
184/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
185/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
186/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
187/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
188/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
189
190-- Dump completed on 2019-10-29 8:13:25