Question: Using the film database you have, answer the following queries in your schema then write them down in this paper. a) Convert the following for-cursor

Using the film database you have, answer the following queries in your schema then write them down in this paper.  Using the film database you have, answer the following queries in
a) Convert the following for-cursor into: open, fetch, close one:
DECLARE
Cursor c1 is select table_name from user_tables;
BEGIN
FOR tables IN c1 LOOP
DBMS_OUT.PUT_LINE(tables.table_name);
END LOOP;
END;
b) Create a trigger so that when user tries to update category table, new value won't take effect and old data will remain in the database.
c) Create a function to return if a particular film has more than 10 actors in it or not.

PF actor id PF Simid Film Actor SMALLINT SMALLINT Language Planguage_id SMALLINT name CHAR (20) Pfilm_id title description release_year Flanguage_id F original_language_id rental duration rental rate length replacement_cost Film SMALLINT VARCHAR2 (255) VARCHAR2 (255) SMALLINT SMALLINT SMALLINT SMALLINT NUMBER (42) SMALLINT NUMBER (52) VARCHAR2 (6) VARCHAR2 (255) TIMESTAMP Film Category PF film_id SMALLINT EPF category_id SMALLINT rating Pactor_id first_name last_name Fnationality Actor SMALLINT VARCHAR2 (45) VARCHAR2 (45) CHAR (2) special features last update Country P. country_id SMALLINT U short code CHAR (2) VARCHAR2 (25) Category P.category_id SMALLINT name VARCHAR2 (25) parent.cat SMALLINT .name

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!