How to get dates from a table while the date range is from the date belonging to another table?
You can use the BETWEEN conditional operator to search for anything in a range. The BETWEEN operater is inclusive so will find records for the start and end dates too.

You will be able to query the attendance table directly:

SELECT * FROM attendance WHERE attendancedate BETWEEN '2019-04-03' AND '2019-06-03'

This question has some examples:
https://stackoverflow.com/questions/3822648/how-do-i-query-between-two-dates-using-mysql

I hope that helps!