Table: municipalities_quebec_2
Columns: code
type
name
area_km_2
population
regional_county_municipality
region

Question: What is the smallest population in a region greater than 9?
SQL: SELECT MIN("population") FROM municipalities_quebec_2 WHERE "region" > 9

Question: What is the average area for code 98030 with population over 312?
SQL: SELECT AVG("area_km_2") FROM municipalities_quebec_2 WHERE "code" = 98030 AND "population" > 312