What's wrong with my SQL query?

the query i wrote is failing to filter by the ‘type’ field:

$data = mysql_query(“SELECT * FROM phys WHERE location = ‘$sv’ OR location2 = ‘$sv’ AND type = ‘resident’ ORDER BY lastName”

what the heck is wrong with me?