Add ids, results and records to search