CREATE TABLE "subdivisions" (
  "name" text,
  "geographic_code" text,
  "type" text,
  "households" real,
  "population_2004" real,
  "foreign_population" real,
  "moroccan_population" real
);

Question: What is the lowest 2004 population when there were 5158 households?
SQL: SELECT MIN("population_2004") FROM "subdivisions" WHERE "households"=5158;

Question: What is the number for the Moroccan population when the name is Sebt Saiss and the 2004 population is more than 11212?
SQL: SELECT COUNT("moroccan_population") FROM "subdivisions" WHERE "name"='sebt saiss' AND "population_2004">11212;

Question: What is the largest foreign population when the 2004 population is 7641?
SQL: SELECT MAX("foreign_population") FROM "subdivisions" WHERE "population_2004"=7641;