Okay - I have a database of all my family and friend's birthdays the field is
date_of_event
I want to display all the Birthday's that are coming up in the next month, are today, or were in the last week - all from one query if possible and showing how many days ago it was, or days until it will be.
So far I have written this:
SELECT title, date_of_event
FROM calender_system
WHERE month(date_of_event)
BETWEEN month(DATE_SUB(now(),INTERVAL 7 DAY))
AND month(DATE_ADD(now(),INTERVAL 1 MONTH))
However this gets all Birthdays for the last month, this month and the current month - so how do I
1) make it just for the last week and the next month; and
2) calculate the number of days until or from the birthday
thanks for your help