What are the race ids that the driver with the surname Nakajima was in?
SELECT T2.raceID FROM drivers AS T1 JOIN results AS T2 ON T1.driverid  =  T2.driverid where T1.surname = "Nakajima"
driver with the surname Nakajima refers to T1.surname = 'Nakajima'; race ids that the driver was in refers to SELECT T2.raceID; JOIN is used to connect drivers and results tables on driverid.