Question: For this question, you'll switch back to the Sakila database. Your boss, at movies - rentals - to - go asks you to create a

For this question, you'll switch back to the Sakila database.
Your boss, at movies-rentals-to-go asks you to create a list of all the movies where the movie description contains either sharks,
cows or crocodiles that are either dramas, comedys, or character studies. They provide you this query, which gives them the results
they want, but the query isn't performant.
SELECT
film_id,
title,
description
FROM
film
WHERE
(description LIKE '%shark%' OR
description LIKE '%cow%' OR
description LIKE '%crocodile%') and
(description LIKE '%drama%' OR
description LIKE '%comedy%' OR
description LIKE '%character study%') order by title;
Write a query using a full text index that gives the same results, but with better performance. Can you get an exact match? Why or
why not? If not, is there any way to adjust the query to get the same result?

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!