Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
20181CSE0068
create table employee(ssn int primary key, name varchar(20) not null, address varchar(20), salary int, sex varchar(10)); create table department(dno int primary key, dname varchar(10),mgrssn int); create table project(pno int primary key, pname varchar(10),ploctation varchar(20),dno int, foreign key (dno) references department(dno) on delete cascade) ; create table Workson(ssn int, pno int, hours int, foreign key (ssn) references employee(ssn) on delete cascade, foreign key(pno) references project(pno) on delete cascade) ; insert into employee values (1,'nithesh', 'Banglore', 10000,'male'); select *from employee; insert into employee values(2,'krishna', 'hyderabad', 15000,'male'); insert into employee values(3,'hari','pune',20000,'male'); insert into employee values (4,'sam','delhi',30000,'female'); insert into employee values(5,'nikita', 'mumbai', 40000,'female') ; select *from employee; insert into department values (1,'research', 123) ; select *from department ; insert into department values(2,'mining', 345); insert into department values (3,'construction', 567); insert into department values (4,'medical', 678); insert into department values (5,'teaching', 789); select *from department; insert into project values(101,'roads', 'bangalore',
run
|
edit
|
history
|
help
0
table emp
sql6
6
DeletorWall
Shalvika's Query
kuy09:admin09@pkms99.info
DBMS 4/9/20
Get amount of users that bought something soon after registration
Ranking split across tournaments
student table create