CREATE TABLE "race" (
  "driver" text,
  "constructor" text,
  "laps" real,
  "time_retired" text,
  "grid" real
);

Question: What is the highest grid when the race was retired due to the gearbox after 67 laps?
SQL: SELECT MAX("grid") FROM "race" WHERE "time_retired"='gearbox' AND "laps">67;

Question: What was the time of the race for Driver Jarno Trulli on a grid smaller than 13?
SQL: SELECT "time_retired" FROM "race" WHERE "grid"<13 AND "driver"='jarno trulli';

Question: How many laps did Nick Heidfeld drive on grids larger than 4?
SQL: SELECT SUM("laps") FROM "race" WHERE "grid">4 AND "driver"='nick heidfeld';