*IN SQL*
Create the following tables using SQL Commands
State (StateName, StateAbb, Region, Size)
City (CityID, CityName, Population,
CrimeRate)
Add the appropriate foreign key to the MANY
table and enforce referential integrity.
Once you are done creating the two tables with the appropriate
relationship, Write SQL commands to:
a. Show the state name and count how many cities in each state
with ‘High’ crime rate.
b. After grouping all the states with the sum of the population
for their cities, only show these states with the population >=
4,000,000.
*IN SQL* Create the following tables using SQL Commands State (StateName, StateAbb, Region, Size) City (CityID, CityName
-
answerhappygod
- Site Admin
- Posts: 899604
- Joined: Mon Aug 02, 2021 8:13 am
*IN SQL* Create the following tables using SQL Commands State (StateName, StateAbb, Region, Size) City (CityID, CityName
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!