CREATE TABLE MOVIE(
mov_id int NOT NULL,
mov_title varchar(255) NOT NULL,
mov_releaseDate date,
gen_id int NOT NULL,
PRIMARY KEY (mov_id),
FOREIGN KEY (gen_id) REFERENCES GENRE(gen_id)
);
CREATE TABLE GENRE(
PRIMARY KEY (gen_id),
gen_name varchar(255) NOT NULL
);Search movies by year. Using the tables above, create a stored procedure, called getMovieByYear, that, given a year, returns all the movies which were released in that year. It displays the movie title, movie’s genre name, and release year.
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here