SQLize Online / PHPize Online  /  SQLtest Online

A A A
Share      Blog   Popular
Copy Format Clear
create table emp ( id int, name varchar(25), salary number ); insert into emp values(18,'Piyush',25000); insert into emp values(17,'Sujal',20000); insert into emp values(65,'Yash',27000); insert into emp values(61,'Sahil',30000); insert into emp values(40,'Aayush',50000); insert into emp values(23,'Gori',60000); select * from emp; select name from emp; select id,name from emp; alter table emp add(city varchar(25)); update emp SET city='Mumbai'; select * from emp; update emp SET city='Ahmedabad' where id=18; select * from emp; create table emp1 as select * from emp; truncate table emp; select * from emp; rollback; select * from emp; commit; select * from emp; drop table emp; select * from emp; select * from emp1; delete from emp1 where id=61; select * from emp1; create view empview1 as select id,name from emp1; select *from empview1; update emp1 SET city='' where id=23; select * from emp1; select *from empview1; create view empview2 as select id,name from emp1 where city IS NOT NULL; select *from empview2;
Stuck with a problem? Got Error? Ask ChatGPT!
Copy Clear