--1.
Create an ‘Orders’ table which comprises of these columns – ‘order_id’,
‘order_date’, ‘amount’, ‘customer_id’
create table ord(ord_id int primary key, ord_date date, amount int,customer_id int)
insert into ord values(101,'07/31/2022',1500,1);
insert into ord values(102,'01/12/1972',3000,2);
insert into ord values(103,'05/07/2022',2500,3);
insert into ord values(104,'08/15/2022',2000,6);
insert into ord values(105,'11/24/2001',1300,9);
select * from ord
--2.Make an inner join on ‘Customer’ & ‘Ord’ tables on the ‘customer_id’ column
select * from ord
inner join customer c
on ord.customer_id=c.customer_id
--3.Make left and right joins on ‘Customer’ & ‘Order’ tables on the ‘customer_id’
column
select * from ord
left join customer c
on ord.customer_id=c.customer_id
select * from ord
right join customer c
on ord.customer_id=c.customer_id
--4.Update the ‘Orders’ table, set the amount to be 100 where ‘customer_id’ is 3
update orders
set amount = 100
where customer_id = 3
select * from ord