00:01
Hello student, here three tables are given.
00:03
I have taken their name, table 1, table 2, table 3.
00:07
And their columns are given.
00:09
And from this table, we have to select the poster code 90204 from the table 2.
00:18
So here i write the query, select star from table 2 where poster code is equal to 90204.
00:26
So it will display all the data which contains 90204.
00:34
And now we have to create a table where table consists of order id, order date, customer id and customer name from the table 2.
00:50
So here i write a query, select order id, order date, order id and order date from table 1.
01:01
Left hand means it will take the data from the table 2 which is on the left side.
01:08
So left hand from table 2 on table 1 .customid, table 2 .customid because these are the common data in table 1 and in table 2.
01:21
So this table will consist order id.
01:26
I am drawing the table.
01:28
Order id, order id, customer id and after this customer name and date.
01:41
Here date.
01:42
Okay.
01:43
And now the table will be now created.
01:48
And after that i have to select the data so that the table consists of order which have not placed.
02:03
It consists the data which have not placed.
02:06
So i write the query, select customer name from table 2 where not exist.
02:12
Here i have used not exist.
02:14
So with the help of this, it will display those customers which have not existed.
02:23
So select order id from table 1 where table 1 .customid equal to table 2 .customid.
02:32
So it will select those customers who have not placed the order.
02:37
So this is the way of displaying the table which have not placed the order.
02:43
Now in my next query, i have taken the data from the table 2.
02:49
Select star from table 2 where order date is this one.
02:56
This is the given date.
02:58
And according to this date, we have to display the data who have placed the order on this date.
03:04
So i use this date which is given to us where table 1 .customid equal to table 2 .customid...