human
Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. 
###Database Schema: Name, Position, Period, Appearances¹, Goals¹, Nationality²
###Question: How many games had less than 7 goals scored?
gpt
SELECT COUNT Appearances¹ FROM table WHERE Goals¹ = 7