-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathdatabase.txt
89 lines (49 loc) · 3.19 KB
/
database.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
------------------
CODE FOR INTERVIEW
------------------
Do Subscribe our Youtube channel and Please like the video if you liked it
Channel: https://www.youtube.com/channel/UCo9P-eIdR00Fn1gA_ylaHdQ
Instagram
username: codeforinterview
https://www.instagram.com/codeforinterview
Telegram
username: codeforinterview
https://t.me/codeforinterview
---------------------------------------------------
Database Queries for UNIVERSITY MANAGEMENT SYSTEM Project
---------------------------------------------------
1 - Create database
create database universitymanagementsystem;
2 - Use database you just created
use universitymanagementsystem;
3 - Create login table
create table login(username varchar(25), password varchar(25));
4 - Insert some values in the login table
insert into login values('admin', '12345');
5 - Create student table
create table student(name varchar(40), fname varchar(40), rollno varchar(20), dob varchar(40), address varchar(100), phone varchar(20), email varchar(40), class_x varchar(20), class_xii varchar(20), aadhar varchar(20), course varchar(40), branch varchar(40));
6 - Create teacher table
create table teacher(name varchar(40), fname varchar(40), empId varchar(20), dob varchar(40), address varchar(100), phone varchar(20), email varchar(40), class_x varchar(20), class_xii varchar(20), aadhar varchar(20), education varchar(40), department varchar(40));
7 - Create student leave table
create table studentleave(rollno varchar(20), date varchar(50), duration varchar(20));
8 - Create teacher leave table
create table teacherleave(empId varchar(20), date varchar(50), duration varchar(20));
9 - Create table to store subjects
create table subject(rollno varchar(20), semester varchar(20), subject1 varchar(50), subject2 varchar(50), subject3 varchar(50), subject4 varchar(50), subject5 varchar(50));
10 - Create table to store marks
create table marks(rollno varchar(20), semester varchar(20), marks1 varchar(50), marks2 varchar(50), marks3 varchar(50), marks4 varchar(50), marks5 varchar(50));
11 - Create table for fee structure
create table fee(course varchar(20), semester1 varchar(20), semester2 varchar(20), semester3 varchar(20), semester4 varchar(20), semester5 varchar(20), semester6 varchar(20), semester7 varchar(20), semester8 varchar(20));
12 - Insert some values in the table
insert into fee values("BTech", "48000", "43000","43000","43000","43000","43000","43000","43000");
insert into fee values("Bsc", "40000", "35000","35000","35000","35000","35000","",";
insert into fee values("BCA", "35000", "34000","34000","34000","34000","34000","",";
insert into fee values("MTech", "65000", "60000","60000","60000","","","",;
insert into fee values("MSc", "47500", "45000","45000","45000","","",";
insert into fee values("MCA", "43000", "42000","42000","49000","","",";
insert into fee values("Bcom", "22000", "20000","20000","20000","20000","20000","",";
insert into fee values("Mcom", "36000", "30000","30000","30000","","","";
13 - Create table to store student fee details
create table collegefee(rollno varchar(20), course varchar(20), branch varchar(20), semester varchar(20), total varchar(20));
Code For Interview
Channel: https://www.youtube.com/channel/UCo9P-eIdR00Fn1gA_ylaHdQ