Question 1. write a SQL statement to display the flight numbers (FLT_NUM) and flight dates (FLT_DATE) of all the flights on the ASSIGNMENT table whose flight number (AC_NUM) ends with a "G". 2. write a SQL statement to update the aircraft number (AC_NUM) of the flight number (FLT_NUM) equal to 101 and flight date (FLT_DATE) equal to 15 January 2016, to 411H. 3. write a SQL statement to add a new record to table FLIGHT. Make use of prompts to allow tge values for all the fields of the table to be entered. 4. write a SQL statement to give a summary of the total number of flights per aircraft number (AC_NUM) on table ASSIGNMENT. display the total number of flights with a heading "Total Number of Flights". 5. write a SQL statement that lists all flight dates (FLT_DATE), flight origins (FLT_ORIGIN) and flight destinations (FLT_DESTINATION). Sort the list according to descending flight date and ascending flight origin. Database name: Ch02_Airline Table name: AIRCRAFT Table name: ASSIGNMENT AC_NUM 123U 375G 411H AC_MODEL MD-80 B-737 B-737 FLT_NUM FLT_DATE AC_NUM 101 14-Jan-16 375G 101 15-Jan-16 375G 101 16-Jan-16 411H 101 17-Jan-16 375G 101 18-Jan-16 1230 102 14-Jan-16 375G 102 15-Jan-16 375G 102 16-Jan-16 411H 102 17-Jan-16 375G 102 18-Jan-16 1230 Table name: FLIGHT FLT_NUM FLT_ORIGIN FLT_DESTINATION 101 MEM ATL 102 ATL MEM

MON3CD The Asker · Computer Science

1. write a SQL statement to display the flight numbers (FLT_NUM) and flight dates (FLT_DATE) of all the flights on the ASSIGNMENT table whose flight number (AC_NUM) ends with a "G".

2. write a SQL statement to update the aircraft number (AC_NUM) of the flight number (FLT_NUM) equal to 101 and flight date (FLT_DATE) equal to 15 January 2016, to 411H.

3. write a SQL statement to add a new record to table FLIGHT. Make use of prompts to allow tge values for all the fields of the table to be entered.

4. write a SQL statement to give a summary of the total number of flights per aircraft number (AC_NUM) on table ASSIGNMENT. display the total number of flights with a heading "Total Number of Flights".

5. write a SQL statement that lists all flight dates (FLT_DATE), flight origins (FLT_ORIGIN) and flight destinations (FLT_DESTINATION). Sort the list according to descending flight date and ascending flight origin.

Transcribed Image Text: Database name: Ch02_Airline Table name: AIRCRAFT Table name: ASSIGNMENT AC_NUM 123U 375G 411H AC_MODEL MD-80 B-737 B-737 FLT_NUM FLT_DATE AC_NUM 101 14-Jan-16 375G 101 15-Jan-16 375G 101 16-Jan-16 411H 101 17-Jan-16 375G 101 18-Jan-16 1230 102 14-Jan-16 375G 102 15-Jan-16 375G 102 16-Jan-16 411H 102 17-Jan-16 375G 102 18-Jan-16 1230 Table name: FLIGHT FLT_NUM FLT_ORIGIN FLT_DESTINATION 101 MEM ATL 102 ATL MEM
More
Transcribed Image Text: Database name: Ch02_Airline Table name: AIRCRAFT Table name: ASSIGNMENT AC_NUM 123U 375G 411H AC_MODEL MD-80 B-737 B-737 FLT_NUM FLT_DATE AC_NUM 101 14-Jan-16 375G 101 15-Jan-16 375G 101 16-Jan-16 411H 101 17-Jan-16 375G 101 18-Jan-16 1230 102 14-Jan-16 375G 102 15-Jan-16 375G 102 16-Jan-16 411H 102 17-Jan-16 375G 102 18-Jan-16 1230 Table name: FLIGHT FLT_NUM FLT_ORIGIN FLT_DESTINATION 101 MEM ATL 102 ATL MEM