CREATE TABLE table_10171 ("Driver" CLOB, "Constructor" CLOB, "Laps" FLOAT, "Time/Retired" CLOB, "Grid" FLOAT)

Name the highest laps for time/retired of engine and grid of 5
SELECT MAX("Laps") FROM table_10171 WHERE "Time/Retired" = 'engine' AND "Grid" = '5'
SELECT MAX("Laps") FROM "table_10171" WHERE "Grid" = '5' AND "Time/Retired" = 'engine'