her ikisi seçili ise

select * from tablom where sehir=2 and semt=6
sadece şehir seçili ise

select * from tablom where sehir=2