For the following tables called “instructor” and “class”, w…
For the following tables called “instructor” and “class”, write a SQL query to perform the given search. instructor column_name | data_type ————-+——————- id | numeric name | character varyingclass column_name | data_type ————-+———– info | json Example data tables are given below. However, your code should be generic and work with any valid data. instructor id | name —-+—————— 1 | Terence Parr 2 | Yannet Interian 3 | Diane Woodbridge 4 | Shan Wang 5 | Michael Ruddy(5 rows)class info ————————————————– { “name” : “Relational Databases”, “class_id” : “MSDS691”, “instructor_id” : 3, “start_date” : “2021-08-23” } { “name” : “Time Series Analysis”, “class_id” : “MSDS604”, “instructor_id” : 4, “start_date” : “2021-10-18” } { “name” : “EDA and Viosualization”, “class_id” : “MSDS593”, “instructor_id” : 4, “start_date” : “2021-07-05” } { “name” : “Communications for Analytics”, “class_id” : “MSDS610”, “instructor_id” : 5, “start_date” : “2021-08-23” } { “name” : “Intro to Machine Learning”, “class_id” : “MSDS621”, “instructor_id” : 1, “start_date” : “2021-10-18” } { “name” : “Machine Learning Laboratory”, “class_id” : “MSDS699”, “instructor_id” : 3, “start_date” : “2021-10-18” }(6 rows) *You can create the tables using the following queries. CREATE TABLE instructor( id NUMERIC, name VARCHAR, PRIMARY KEY (id));INSERT INTO instructor VALUES(1, ‘Terence Parr’),(2, ‘Yannet Interian’),(3, ‘Diane Woodbridge’),(4, ‘Shan Wang’),(5, ‘Michael Ruddy’);CREATE TABLE class( info json);INSERT INTO class VALUES( ‘{ “name” : “Relational Databases”, “class_id” : “MSDS691”, “instructor_id” : 3, “start_date” : “2021-08-23” }’),( ‘{ “name” : “Time Series Analysis”, “class_id” : “MSDS604”, “instructor_id” : 4, “start_date” : “2021-10-18” }’),( ‘{ “name” : “EDA and Viosualization”, “class_id” : “MSDS593”, “instructor_id” : 4, “start_date” : “2021-07-05” }’),( ‘{ “name” : “Communications for Analytics”, “class_id” : “MSDS610”, “instructor_id” : 5, “start_date” : “2021-08-23” }’),( ‘{ “name” : “Intro to Machine Learning”, “class_id” : “MSDS621”, “instructor_id” : 1, “start_date” : “2021-10-18” }’),( ‘{ “name” : “Machine Learning Laboratory”, “class_id” : “MSDS699”, “instructor_id” : 3, “start_date” : “2021-10-18” }’);