master
1CREATE TABLE movies (
2 id integer NOT NULL,
3 title character varying(255),
4 studio_id integer,
5 year integer
6);
7
8CREATE TABLE studios (
9 id integer NOT NULL,
10 title character varying(255)
11);
12
13-- COPY studios (id, title) FROM stdin;
14-- 1 Castle Rock
15-- 2 MiramaxFilms
16-- 3 RegencyEnterprises
17-- 4 Pixar
18-- 5 Disney
19-- \.
20
21-- find all pixar movies
22-- find all studios that don't have a movie.
23-- find all studios that did not publish a movie in 2006
24-- find all movies published by pixar or disney
25-- find all movies not published by pixar
26-- find all movies released after 2004
27-- find all movies released between 1982 and 2003 - Inclusive
28-- sort all movies by descending title
29-- sort all movies by ascending title
30-- sort all movies by descending release date
31-- sort all movies by ascending release date
32-- sort all movies by preferred studios and release date ascending