selectwhere.sql 986 Bytes
Newer Older
Joel Florentin committed
1 2 3 4 5 6 7 8 9 10 11
select * from film;
select f.actor_id, f.film_id, f.last_update from film_actor as f left join actor on f.actor_id=actor.actor_id where actor.first_name='Johnny' ;
select f.actor_id, f.film_id, f.last_update from film_actor as f left join actor on f.actor_id=actor.actor_id where actor.first_name='Johnny' or  actor.first_name='Penelope';
select f.actor_id, f.film_id, f.last_update from film_actor as f left join actor on f.actor_id=actor.actor_id where actor.first_name='Johnny' and  actor.first_name='Penelope';
select * from film_category as fc left join category as cat
on cat.category_id=fc.category_id where cat.name in ('Action','Comedy');
select * from film where title like 'A%' order by release_year;
select * from film where title like 'B%';
select * from payment where amount between 0 and 5;
select * from film where title<>'Analyze Hoosiers';
select * from film right join inventory as inv on inv.film_id=film.film_id right join store as st on st.store_id = inv.store_id;