0
SQL double where
Trying to set 2 conditions, 1 for > avg price and the other for not rented. I succeeded at the desafĂo, but it wouldnât have worked if one of the expensive apartments had been rented, because my code, below, only accounts for price, not status (rented or not): SELECT * FROM Apartments WHERE Price> (SELECT AVG (price) FROM Apartments) ORDER BY Apartments.Price I tried to add âWHERE Status LIKE ân%ââ after the first where and before ORDER BY. I tried using AND WHERE and just AND. Neither would run.
0 Answers