Project :
Confirmation of the admission of the student to the academic programme after submission of a completed admission form with necessary supporting
Student table:
create table students ( sRoll int primary key auto_increment, sEmail varchar(25) unique not null, sPassword varchar(15) NOT NULL, sName varchar(20) NOT NULL );
Admin table:
create table admin ( adminId int primary key auto_increment, a_name varchar(25) unique not null, a_Pass varchar(15) NOT NULL);
Course table:
create table courses ( c_id int primary key auto_increment, c_name varchar(25) unique not null, fee int NOT NULL, seats int NOT NULL );
Student_Course table:
create table student_course ( roll int, course int, foreign key (roll) references students(sRoll) on delete set null, foreign key (course) references courses(c_id) on delete set null );
Batch table:
create table batch ( bId int primary key auto_increment, bname varchar(25), duration int, cId int, seats int, foreign key (cId) references courses(c_id) ON DELETE Cascade );
student_batch table:
create table student_batch ( roll int, course int, bid int, foreign key (roll) references students(sRoll) ON DELETE CASCADE, foreign key (course) references courses(c_id) ON DELETE CASCADE, foreign key (bid) references batch(bId) ON DELETE CASCADE );
insert into students(semail,spassword,sname) values('Sad@gmail.com','Sad','Sadu');
insert into courses(c_name,fee,seats) values('DSa',5000,0);
insert into admin(a_name,a_Pass) values('Sadichchha','Vikrant');
insert into batch(bname,duration,cId,seats) values('Java',5,1,5090);