CREATE TABLE table_name_54 (total INT, nation VARCHAR, gold VARCHAR)

What is the average total with a nation of thailand with a gold smaller than 17?
SELECT AVG(total) FROM table_name_54 WHERE nation = "thailand" AND gold < 17
SELECT AVG("total") FROM "table_name_54" WHERE "gold" < 17 AND "nation" = "thailand"