CREATE TABLE table_name_40 (opponent VARCHAR2, record VARCHAR2)

Who was the opponent when the record was 31-24?
SELECT opponent FROM table_name_40 WHERE record = "31-24"
SELECT "opponent" FROM "table_name_40" WHERE "31-24" = "record"