Выбор нужных строк. Логические операторы и выражения в WHERE.
select * from film where rental_rate = 4.99; select * from film where rental_rate < 3; select * from film where rental_rate >= 2.99; select * from rental where rental_date between '2005-05-26' and '2005-05-28'; select * from film where title like '%Airport%'; select * from film f where description not like '%Epic%'; select * from address a where address2 is null; select * from address a where address2 is not null; select * from film where rental_duration != 7; -- pokerfpoker -- = > < >= <= like not like is null is not null <> != in between select * from film f where not rental_duration = 7; select * from film f where description not like '%Epic%'; select * from film f where not (description like '%Epic%'); select * from film f where rental_duration in (6, 7) and rental_rate > 1 and title like 'P%'; select * from film where rental_duration = 1 or rental_duration = 6 or title like 'P%'; select * from film f where f.rental_duration in (6, 7) or f.rental_rate > 1 and f.title like 'P%' or f.length between 70 and 120 and f.rating = 'PG'; select * from film f where ( rental_duration in (6, 7) or rental_rate > 1 ) and ( title like 'P%' or length between 70 and 120 ) and rating = 'PG';