We help IT Professionals succeed at work.

sql 2008 example of a sub query

How would I write this query?
      Write a subquery which finds all of the employees who live in the same city as Steven Buchanan.
Comment
Watch Question

Commented:
select * from employees where city IN (select distinct city from employees where employeeName = "Steven Buchanan")
Commented:
Sorry - single quotes instead....

select * from employees where city IN (select distinct city from employees where employeeName = 'Steven Buchanan"')
AneeshDatabase Consultant
Top Expert 2009
Commented:
select * from employees where city IN (select city from employees where employeeName = 'Steven Buchanan')