Table: mets_2008_game_2
Columns: date
opponent
score
loss
attendance
record

Question: What was the average attendance when the record was 58–49?
SQL: SELECT AVG("attendance") FROM mets_2008_game_2 WHERE "record" = '58–49'

Question: What was the attendance when the score was 8–7?
SQL: SELECT SUM("attendance") FROM mets_2008_game_2 WHERE "score" = '8–7'

Question: What was the attendance for july 18?
SQL: SELECT COUNT("attendance") FROM mets_2008_game_2 WHERE "date" = 'july 18'