Hello and welcome to this video.
In the previous video, we have created a table by the name implies we have added rerecords into it.
So now let's complete the lab exercise.
So the first exercises find the name of all the employees, so I'll quickly go to the localhost and
a query that is select staff from employees, which is going to give me all the records from the employees
table.
So the second thing is list all the employees who are working in I.T. So how to do that?
We have discussed it previously that if you want to put any condition, we can use some conditional
clause such as their clause.
So now we are going to go on to the localhost, go to a school.
And we want to fetch all the different records present in the employees stable where?
Employee department is equal to I.T., so it is going to give me all the records present in the table
who all walks in to the city department head, don't go.
You'll see.
The result is only Heti is the person from the whole employee's table who works in the I.T. department.
So I am getting the result as such.
So now moving on, the third question is sure, different types of departments, so how to find out
different types of department present, so select distinct the column name that is employed department
from employee stable.
So this is the key word used to find out the unique values present in a particular column.
So we are going to find out the different departments present in the table, employees.
So you see there are three different departments that has been Enzyte in H.R. So this is the solution
of all the three exercises which I have given you, you can practice a lot more.
There are so many resources around the Internet so you can find out such questions and practice on yourself.
So that's it for this video.
Thank you so much.