The title might be a bit misleading, but what I want is:
SELECT * FROM table ORDER BY pid ASC
And in one of the columns I have a DATE(). I want to compare the current date (not time) and return how many days are left till that date. Let's say the date is 2013-04-20
and today's date is 2013-04-16
I don't want to get any data if it's < current date
. If it is I want it returned in days.
I've been looking around here and I've found no way to do it, and I can't for the love of me figure it out.