CREATE TABLE "junior_career_history" (
  "year" real,
  "competition_description" text,
  "location" text,
  "apparatus" text,
  "rank_final" text
);

Question: What year was the rank final of 6?
SQL: SELECT "year" FROM "junior_career_history" WHERE "rank_final"='6';

Question: What was the rank final before 2007?
SQL: SELECT "rank_final" FROM "junior_career_history" WHERE "year"<2007;