Question
Create the Employee/Department database (script provided below). Write and run a PL/SQL block which produces a report listing world regions, countries in those regions, the
Create the Employee/Department database (script provided below).
Write and run a PL/SQL block which produces a report listing world regions, countries in those regions, the population and the currency info for each country.
You will need two cursors: an outer loop cursor which fetches and displays rows from the REGIONS table, and an inner loop cursor which fetches and displays rows from the COUNTRIES table for countries in that region, passing the region_id as a parameter. You also need to use the CURRENCIES table to retrieve the currency information for each country in this cursor. Include your first and last name in the title line of the results
Restrict your regions to those in the Africa (region_name like '%Africa%'). Order your output by region_name, and by country_name within each region. Your output should look something like this (only the first few records are shown):
14 Eastern Africa by Ann Aksut Federal Democratic Republic of Ethiopia - Population: 74777981 Currency: ETB birr Republic of Djibouti - Population: 486530 - Currency: DJF Djiboutian franc Republic of Kenya - Population: 34707817 Currency: KES Kenyan shilling Republic of Uganda - Population: 28195754- Currency: UGX Ugandan shilling Somalia - Population: 8863338 - Currency: SOS Somali shilling state of Eritrea - Population: 4786994 Currency: ERN nakfa United Republic of Tanzania - Population: 37445392- Currency: TZS Tanzanian shilling 17 Middle Africa by Ann Aksut Central African Republic - Population: 4303356- Currency: XAF Communaute Financiere Africaine franc Democratic Republic of the Congo - Population: 62660551 - Currency: CDF Congolese franc Republic of Burundi - Population: 8090068 - Currency: BIF Burundi franc Republic of Chad - Population: 9944201 - Currency: XAF Communaute Financiere Africaine franc Republic of Rwanda - Population: 8648248- Currency: RWF Rwandan franc 15 Northern Africa by Ann Aksut Arab Republic of Egypt - Population: 78887007- Currency: EGP Egyptian pound Great Socialist Peoples Libyan Arab Jamahiriya - Population: 5900754 Currency: LYD Libyan dinar Islamic Republic of Mauritania - Population: 3177388 - Currency: MRO ouguiya
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Creating and running a PLSQL block to produce a report as described involves multiple SQL statements ...Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started