SQLize Online / PHPize Online  /  SQLtest Online

A A A
Share      Blog   Popular
Copy Format Clear
create table emp ( ename varchar(20), ecity varchar(20), esalary number, enumber int, eaddress varchar(30), deptname varchar(20) ); insert into emp values('Rashi','mumbai',5000,4,'Block 101','HR'); insert into emp values('Aditi','delhi',5000,4,'Block 101','HR'); insert into emp values('Yash','mumbai',5000,7,'Block 101','HR'); insert into emp values('Piyush','delhi',5000,4,'Block 101','HR'); insert into emp values('Sujal','mumbai',5000,4,'Block 101','HR'); select * from emp; create table company ( cname varchar(20), ccity varchar(20), empnumber number ); insert into company values('Ram','delhi',101); insert into company values('Shyam','delhi',102); insert into company values('Tony','delhi',103); select * from company; select cname from company where ccity='delhi'; update emp set esalary=10000; select *from emp; update emp set esalary=15000 where ename='Rashi'; select *from emp; select ename from emp where esalary>10000; update company set ccity='mumbai' where cname='Ram'; select *from company; alter table emp add (desig varchar(20)); select*from emp; update emp set desig='manager'; select *from emp; alter table emp drop(esalary); select *from emp; delete from emp where enumber=7; select *from emp;

Stuck with a problem? Got Error? Ask ChatGPT!

Copy Clear