add waiting_time with select