Question: Having trouble with the code below. I am building a Vertical Database Partitioning. I am building a new table cast_bio from the movie_cast table (i.e.,

Having trouble with the code below.  I am building a Vertical Database Partitioning.  I am building a new table cast_bio from the movie_cast table (i.e., columns in cast_bio will be a subset of those in movie_cast). I will have to insert into the new cast_bio that the values are unique.  This is cast_bio table I need to build with values I will pull from the movie_cast table.


cast_bio 1. cast_id (integer) 2. cast_name (text) 3. birthday (date) 4. popularity (real)


# Part a.iii Vertical Database Partitioning [5 points]

    def part_aiii(self,connection):

        ############### EDIT CREATE TABLE SQL STATEMENT ###################################

        part_aiii_sql = ""

        ######################################################################

        

        self.execute_query(connection, part_aiii_sql)

        

        ############### CREATE IMPORT CODE BELOW ############################

        part_aiii_insert_sql = ""

        ######################################################################

        

So I have a table named movie_cast table and the values in movie_ cast are     (movie_id integer, cast_id integer, cast_name text, birthday text, popularity real);";  I need to edit that table using the Veritcal Database Partitioning with a new table labeled cast_bio.  This table will have 1. cast_id (integer) 2. cast_name (text) 3. birthday (date) 4. popularity (real).  So I will input them in the Edit Table and Create Table area that is comment out.

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!