CREATE TABLE "table1_166346_1" (
  "country" text,
  "region" text,
  "joined_opec" real,
  "population_july_2012" real,
  "area_km" real,
  "production_bbl_day" text
);

Question: When did the country that produced 1,213,000 (21st) bbl/day join Opec?
SQL: SELECT "joined_opec" FROM "table1_166346_1" WHERE "production_bbl_day"='1,213,000 (21st)';

Question: What was the minimum area in square kilometers that produced 3,200,000 (12th) bbl/day?
SQL: SELECT MIN("area_km") FROM "table1_166346_1" WHERE "production_bbl_day"='3,200,000 (12th)';

Question: What is the highest poplulation in July 2012 in the country with an area of 2149690 square kilometers?
SQL: SELECT MAX("population_july_2012") FROM "table1_166346_1" WHERE "area_km"=2149690;

Question: Which regions had a production (bbl/day) of 1,213,000 (21st)?
SQL: SELECT "region" FROM "table1_166346_1" WHERE "production_bbl_day"='1,213,000 (21st)';

Question: Which country had a production (bbl/day) of 2,494,000 (10th)?
SQL: SELECT "country" FROM "table1_166346_1" WHERE "production_bbl_day"='2,494,000 (10th)';