How do I write an SQL query to find out which employees are from a single location where employee and location are different table.
select count(*) from employee;
The above gives only the count of employees but I need to display their name and location
COUNTwill obviously give you only the count of the number of employees.For specific columns such as ‘name’ and ‘location’, just do:
(or JOIN on whatever is the common association column between the
employeeandlocationtable)