Date fields in MySQL, finding all rows that don't overlap and returning only the difference
问题 So this was one of my very first questions here, but I have a slight variation: So I have two people whose schedules are in a database. The schedules simply record the start time, end time, and description of the various events/appointments for both users. PersonA wants to trade appointments with PersonB. I want a MySQL query that will return all of them times that PersonB and PersonA can swap. Originally the parameters of the query were to throw out any appointments of PersonB where there