Please accept my apologies for a lack of attempted code.
I can't get my head around this - or even figure out if it's feasible!
I have a table filled with 'date slots', these can be booked by an individual.
The time slots table looks like this:
ID | Price | Available_from | Available_ to
------------------------------------
1 | 20.00 | 2017-10-01 | 2018-01-01
2 | 20.00 | 2017-11-01 | 2017-12-07
3 | 20.00 | 2017-10-31 | 2018-01-31
4 | 20.00 | 2017-10-22 | 2017-11-21
------------------------------------
In these rows, there is a common date range where all four results are available, 2017-11-01 > 2017-11-21
I would like to query my database to see if 1) there is a common range for every result and 2) if there is, get the date range.
Desperate for help!
Thank you