create table student(name varchar(20),age int, rollno int primary key,department varchar(10));
insert into student values("rsha",18,101,"IT");
insert into student values("Nisha",20,102,"CS");
insert into student values("Shaurya",23,103,"MECH");
insert into student values("Viraj",28,104,"IT");
select * from student;
select * from student where age>20;
select count(name) from student;
select avg(age) from student;
select min(age) from student;
select max(age) from student;
select sum(age) from student;
Alter table student add column salary int;
Update student set age=24 where rollno=101;
select * from student order by name ASC;
select * from student where age>18 and department='IT';
update student set salary=67000 where rollno=101;
update student set salary=87000 where rollno=102;
update student set salary=98000 where rollno=103;
update student set salary=25000 where rollno=104;
select name from student where salary > (select min(ITstudent.salary) from student as ITstudent where ITstudent.department='IT');
delete from student where student.name like'r%';
select * from student;
select department from student group by department having avg(salary)>(select avg(Salary) from student where department='IT');
select name from student where salary>(select min(Salary) from student where department='IT');
delimiter // ;
Create procedure myProcedure (
   IN name VARCHAR(20),
    IN age int,IN rollno int,IN department varchar(20),
   IN salary int)
BEGIN
INSERT INTO student(name,age,rollno,department,salary) VALUES (name,age,rollno,department,salary);
end //

Embed on website

To embed this program on your website, copy the following code and paste it into your website's HTML: