Task: Text to Code
Input (English): What are the arriving date and the departing date of the dogs who have gone through a treatment?
Output (English): SELECT DISTINCT T1.date_arrived ,  T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id  =  T2.dog_id